home *** CD-ROM | disk | FTP | other *** search
Unknown | 1992-11-30 | 22.4 KB |
open in:
MacOS 8.1
|
Win98
|
DOS
view JSON data
|
view as text
This file was not able to be converted.
This format is not currently supported by dexvert.
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| file
| data
| default
| |
100%
| TrID
| MP3 audio
| default (weak)
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| ff e1 ff e2 02 f6 02 41 | 00 00 00 00 02 d7 02 23 |.......A|.......#|
|00000010| 00 0c 00 00 00 00 02 d7 | 02 23 11 01 0c 00 1e 00 |........|.#......|
|00000020| 1f 01 00 0a 00 00 00 00 | 03 15 02 5f 2c 00 08 00 |........|..._,...|
|00000030| 14 05 54 69 6d 65 73 03 | 00 14 04 01 0d 00 18 2e |..Times.|........|
|00000040| 00 04 00 00 00 00 2b 48 | 48 14 41 70 70 6c 65 20 |......+H|H.Apple |
|00000050| 45 76 65 6e 74 20 52 65 | 67 69 73 74 72 79 04 00 |Event Re|gistry..|
|00000060| 0d 00 0c 28 00 48 02 1c | 07 33 2f 32 32 2f 39 32 |...(.H..|.3/22/92|
|00000070| 04 01 0d 00 0e 28 00 72 | 00 48 09 4c 61 62 20 4e |.....(.r|.H.Lab N|
|00000080| 6f 74 65 73 29 6c 0f 28 | 52 65 67 69 73 74 72 79 |otes)l.(|Registry|
|00000090| 20 2f 20 44 31 29 28 00 | 93 00 48 05 47 6f 61 6c | / D1)(.|..H.Goal|
|000000a0| 73 04 00 0d 00 0c 2b 24 | 18 02 31 2e 29 12 35 49 |s.....+$|..1.).5I|
|000000b0| 6d 70 6c 65 6d 65 6e 74 | 20 74 68 65 20 4f 62 6a |mplement| the Obj|
|000000c0| 65 63 74 20 44 69 73 70 | 61 74 63 68 65 72 20 63 |ect Disp|atcher c|
|000000d0| 6f 64 65 20 66 6f 72 20 | 74 68 65 20 63 61 6c 65 |ode for |the cale|
|000000e0| 6e 64 61 72 2a 0c 2e 61 | 70 70 6c 69 63 61 74 69 |ndar*..a|pplicati|
|000000f0| 6f 6e 2c 20 69 6e 63 6c | 75 64 69 6e 67 20 74 68 |on, incl|uding th|
|00000100| 65 20 63 41 70 70 6f 69 | 6e 74 6d 65 6e 74 6f 62 |e cAppoi|ntmentob|
|00000110| 6a 65 63 74 2e 04 01 0d | 00 0e 28 00 d8 00 48 0e |ject....|..(...H.|
|00000120| 50 72 65 2d 72 65 71 75 | 69 73 69 74 65 73 04 00 |Pre-requ|isites..|
|00000130| 0d 00 0c 28 00 cf 00 6c | 38 59 6f 75 20 6d 75 73 |...(...l|8You mus|
|00000140| 74 20 68 61 76 65 20 63 | 6f 6d 70 6c 65 74 65 64 |t have c|ompleted|
|00000150| 20 74 68 65 20 4f 53 4c | 2f 45 20 4c 61 62 20 28 | the OSL|/E Lab (|
|00000160| 69 6d 70 6c 65 6d 65 6e | 74 61 74 69 6f 6e 20 6f |implemen|tation o|
|00000170| 66 2a 0c 42 63 41 70 70 | 6f 69 6e 74 6d 65 6e 74 |f*.BcApp|ointment|
|00000180| 20 61 63 63 65 73 73 6f | 72 73 29 2e 20 20 49 66 | accesso|rs). If|
|00000190| 20 79 6f 75 20 68 61 76 | 65 20 6e 6f 74 2c 20 74 | you hav|e not, t|
|000001a0| 68 65 6e 20 63 6f 70 79 | 20 61 6e 64 20 70 61 73 |hen copy| and pas|
|000001b0| 74 65 20 74 68 65 2a 0c | 3e 73 6f 6c 75 74 69 6f |te the*.|>solutio|
|000001c0| 6e 20 63 6f 64 65 20 66 | 6f 72 20 74 68 61 74 20 |n code f|or that |
|000001d0| 20 6c 61 62 20 66 72 6f | 6d 20 74 68 65 20 73 6f | lab fro|m the so|
|000001e0| 6c 75 74 69 6f 6e 73 20 | 66 6f 6c 64 65 72 20 69 |lutions |folder i|
|000001f0| 6e 74 6f 20 74 68 65 2a | 0c 11 6c 61 62 5f 4f 53 |nto the*|..lab_OS|
|00000200| 4c 5f 45 2e 63 20 66 69 | 6c 65 2e a0 00 82 a0 00 |L_E.c fi|le......|
|00000210| 8c a1 00 b6 00 04 00 20 | 00 80 01 00 0a 01 08 01 |....... |........|
|00000220| 7a 01 94 02 34 30 01 24 | 01 a2 01 4f 01 fe a1 00 |z...40.$|...O....|
|00000230| b6 00 04 00 01 00 01 07 | 00 00 00 00 22 01 09 01 |........|...."...|
|00000240| 7b 00 00 a1 00 b6 00 04 | 00 20 00 80 07 00 01 00 |{.......|. ......|
|00000250| 01 30 01 09 01 f4 01 18 | 02 1e a1 00 b6 00 04 00 |.0......|........|
|00000260| 01 00 01 07 00 00 00 00 | 23 00 00 a1 00 64 00 08 |........|#....d..|
|00000270| 4d 44 50 4c 00 07 00 00 | 09 00 00 00 00 00 00 00 |MDPL....|........|
|00000280| 00 31 01 0c 01 fe 01 12 | 02 17 a1 00 96 00 0c 01 |.1......|........|
|00000290| 00 00 00 02 00 00 00 00 | 00 00 00 a1 00 9a 00 08 |........|........|
|000002a0| ff fd 00 00 00 0b 00 00 | 01 00 0a 01 0c 01 fe 01 |........|........|
|000002b0| 12 02 17 0d 00 06 2e 00 | 04 00 00 01 00 10 00 8c |........|........|
|000002c0| 00 ba 00 8c 00 ba 28 01 | 11 01 ff 08 45 76 74 48 |......(.|....EvtH|
|000002d0| 64 6c 72 33 a0 00 97 a1 | 00 64 00 08 4d 44 50 4c |dlr3....|.d..MDPL|
|000002e0| 00 08 00 00 a1 00 b6 00 | 04 00 20 00 80 01 00 0a |........|.. .....|
|000002f0| 01 08 01 7a 01 94 02 34 | 07 00 01 00 01 09 ff ff |...z...4|........|
|00000300| ff ff ff ff ff ff 30 01 | 09 01 7b 01 18 01 a5 a1 |......0.|..{.....|
|00000310| 00 b6 00 04 00 01 00 01 | 07 00 00 00 00 22 01 11 |........|....."..|
|00000320| 02 15 00 00 a1 00 b6 00 | 04 00 20 00 80 07 00 01 |........|.. .....|
|00000330| 00 01 30 01 09 01 ae 01 | 18 01 d8 a1 00 b6 00 04 |..0.....|........|
|00000340| 00 01 00 01 07 00 00 00 | 00 23 00 00 a1 00 b6 00 |........|.#......|
|00000350| 04 00 20 00 80 09 80 00 | 00 00 08 00 00 00 31 01 |.. .....|......1.|
|00000360| 27 01 b0 01 31 01 f0 07 | 00 01 00 01 09 ff ff ff |'...1...|........|
|00000370| ff ff ff ff ff 38 a1 00 | b6 00 04 00 01 00 01 07 |.....8..|........|
|00000380| 00 00 00 00 23 00 00 a1 | 00 b6 00 04 00 20 00 80 |....#...|..... ..|
|00000390| 09 80 00 00 00 08 00 00 | 00 31 01 35 01 b0 01 3f |........|.1.5...?|
|000003a0| 01 f0 07 00 01 00 01 09 | ff ff ff ff ff ff ff ff |........|........|
|000003b0| 38 a1 00 b6 00 04 00 01 | 00 01 07 00 00 00 00 23 |8.......|.......#|
|000003c0| 00 00 a1 00 b6 00 04 00 | 20 00 80 09 80 00 00 00 |........| .......|
|000003d0| 08 00 00 00 31 01 42 01 | b0 01 4c 01 f0 07 00 01 |....1.B.|..L.....|
|000003e0| 00 01 09 ff ff ff ff ff | ff ff ff 38 a1 00 b6 00 |........|...8....|
|000003f0| 04 00 01 00 01 07 00 00 | 00 00 23 00 00 a1 00 64 |........|..#....d|
|00000400| 00 08 4d 44 50 4c 00 07 | 00 00 09 00 00 00 00 00 |..MDPL..|........|
|00000410| 00 00 00 31 01 0c 01 85 | 01 12 01 9d a1 00 96 00 |...1....|........|
|00000420| 0c 01 00 00 00 02 00 00 | 00 00 00 00 00 a1 00 9a |........|........|
|00000430| 00 08 ff fd 00 00 00 0b | 00 00 01 00 0a 01 0c 01 |........|........|
|00000440| 85 01 12 01 9d 28 01 11 | 01 86 08 45 76 74 48 64 |.....(..|...EvtHd|
|00000450| 6c 72 31 a0 00 97 a1 00 | 64 00 08 4d 44 50 4c 00 |lr1.....|d..MDPL.|
|00000460| 08 00 00 a1 00 64 00 08 | 4d 44 50 4c 00 07 00 00 |.....d..|MDPL....|
|00000470| 01 00 0a 01 08 01 7a 01 | 94 02 34 31 01 0c 01 b8 |......z.|..41....|
|00000480| 01 12 01 d0 a1 00 96 00 | 0c 01 00 00 00 02 00 00 |........|........|
|00000490| 00 00 00 00 00 a1 00 9a | 00 08 ff fd 00 00 00 0a |........|........|
|000004a0| 00 00 01 00 0a 01 0c 01 | b8 01 12 01 d0 29 33 08 |........|.....)3.|
|000004b0| 45 76 74 48 64 6c 72 32 | a0 00 97 a1 00 64 00 08 |EvtHdlr2|.....d..|
|000004c0| 4d 44 50 4c 00 08 00 00 | a0 00 8c a1 00 b6 00 04 |MDPL....|........|
|000004d0| 00 20 00 80 01 00 0a 01 | 08 01 7a 01 94 02 34 09 |. ......|..z...4.|
|000004e0| ff ff ff ff ff ff ff ff | 51 01 0f 01 dc 01 11 01 |........|Q.......|
|000004f0| de 07 00 01 00 01 58 a1 | 00 b6 00 04 00 01 00 01 |......X.|........|
|00000500| 07 00 00 00 00 22 01 11 | 01 cf 00 00 a1 00 b6 00 |....."..|........|
|00000510| 04 00 20 00 80 51 01 0f | 01 e0 01 11 01 e2 07 00 |.. ..Q..|........|
|00000520| 01 00 01 58 a1 00 b6 00 | 04 00 01 00 01 07 00 00 |...X....|........|
|00000530| 00 00 23 00 00 a1 00 b6 | 00 04 00 20 00 80 51 01 |..#.....|... ..Q.|
|00000540| 0f 01 e5 01 11 01 e7 07 | 00 01 00 01 58 a1 00 b6 |........|....X...|
|00000550| 00 04 00 01 00 01 07 00 | 00 00 00 23 00 00 a0 00 |........|...#....|
|00000560| 8d a1 00 64 00 08 4d 44 | 50 4c 00 07 00 00 09 00 |...d..MD|PL......|
|00000570| 00 00 00 00 00 00 00 31 | 01 29 01 b7 01 30 01 eb |.......1|.)...0..|
|00000580| a1 00 96 00 0c 01 00 00 | 00 02 00 00 00 00 00 00 |........|........|
|00000590| 00 a1 00 9a 00 08 ff fe | 00 00 00 19 00 00 01 00 |........|........|
|000005a0| 0a 01 29 01 b7 01 30 01 | eb 28 01 2e 01 b8 11 63 |..)...0.|.(.....c|
|000005b0| 6f 6d 6d 6f 6e 20 70 61 | 72 61 6d 20 68 64 6c 67 |ommon pa|ram hdlg|
|000005c0| a0 00 97 a1 00 64 00 08 | 4d 44 50 4c 00 08 00 00 |.....d..|MDPL....|
|000005d0| a1 00 64 00 08 4d 44 50 | 4c 00 07 00 00 01 00 0a |..d..MDP|L.......|
|000005e0| 01 08 01 7a 01 94 02 34 | 31 01 37 01 c0 01 3e 01 |...z...4|1.7...>.|
|000005f0| d7 a1 00 96 00 0c 01 00 | 00 00 02 00 00 00 00 00 |........|........|
|00000600| 00 00 a1 00 9a 00 08 ff | fe 00 00 00 0a 00 00 01 |........|........|
|00000610| 00 0a 01 37 01 c0 01 3e | 01 d7 2b 09 0e 06 54 6f |...7...>|..+...To|
|00000620| 6b 47 65 6e a0 00 97 a1 | 00 64 00 08 4d 44 50 4c |kGen....|.d..MDPL|
|00000630| 00 08 00 00 a1 00 64 00 | 08 4d 44 50 4c 00 07 00 |......d.|.MDPL...|
|00000640| 00 01 00 0a 01 08 01 7a | 01 94 02 34 31 01 44 01 |.......z|...41.D.|
|00000650| c2 01 4a 01 e1 a1 00 96 | 00 0c 01 00 00 00 02 00 |..J.....|........|
|00000660| 00 00 00 00 00 00 a1 00 | 9a 00 08 ff fd 00 00 00 |........|........|
|00000670| 0e 00 00 01 00 0a 01 44 | 01 c2 01 4a 01 e1 2b 02 |.......D|...J..+.|
|00000680| 0d 08 4f 62 6a 53 77 63 | 68 72 a0 00 97 a1 00 64 |..ObjSwc|hr.....d|
|00000690| 00 08 4d 44 50 4c 00 08 | 00 00 a1 00 b6 00 04 00 |..MDPL..|........|
|000006a0| 20 00 80 01 00 0a 01 08 | 01 7a 01 94 02 34 07 00 | .......|.z...4..|
|000006b0| 01 00 01 09 ff ff ff ff | ff ff ff ff 22 01 4b 01 |........|....".K.|
|000006c0| cf 00 08 a1 00 b6 00 04 | 00 01 00 01 07 00 00 00 |........|........|
|000006d0| 00 23 00 00 a1 00 b6 00 | 04 00 20 00 80 07 00 01 |.#......|.. .....|
|000006e0| 00 01 22 01 17 01 89 29 | 0d a1 00 b6 00 04 00 01 |.."....)|........|
|000006f0| 00 01 07 00 00 00 00 23 | 00 00 a1 00 b6 00 04 00 |.......#|........|
|00000700| 20 00 80 07 00 01 00 01 | 22 01 17 01 c2 00 0d a1 | .......|".......|
|00000710| 00 b6 00 04 00 01 00 01 | 07 00 00 00 00 23 00 00 |........|.....#..|
|00000720| a1 00 b6 00 04 00 20 00 | 80 07 00 01 00 01 22 01 |...... .|......".|
|00000730| 17 02 05 e3 0d a1 00 b6 | 00 04 00 01 00 01 07 00 |........|........|
|00000740| 00 00 00 23 00 00 a1 00 | 96 00 0c 01 00 00 00 02 |...#....|........|
|00000750| 00 00 00 00 00 00 00 a1 | 00 9a 00 08 ff fe 00 00 |........|........|
|00000760| 00 0a 00 00 01 00 0a 01 | 69 02 1c 01 70 02 33 04 |........|i...p.3.|
|00000770| 01 2b 5a 25 06 4f 62 6a | 65 63 74 a0 00 97 a1 00 |.+Z%.Obj|ect.....|
|00000780| 96 00 0c 01 00 00 00 02 | 00 00 00 00 00 00 00 a1 |........|........|
|00000790| 00 9a 00 08 00 00 00 00 | 00 0d 00 00 01 00 0a 01 |........|........|
|000007a0| 2e 02 02 01 3a 02 20 28 | 01 33 02 03 08 4f 62 6a |....:. (|.3...Obj|
|000007b0| 65 63 74 20 0d 2a 06 0a | 44 69 73 70 61 74 63 68 |ect .*..|Dispatch|
|000007c0| 65 72 a0 00 97 a1 00 b6 | 00 04 00 20 00 80 01 00 |er......|... ....|
|000007d0| 0a 01 08 01 7a 01 94 02 | 34 07 00 01 00 01 22 01 |....z...|4.....".|
|000007e0| 31 01 ce 00 04 a1 00 b6 | 00 04 00 01 00 01 07 00 |1.......|........|
|000007f0| 00 00 00 23 00 00 a1 00 | b6 00 04 00 20 00 80 07 |...#....|.... ...|
|00000800| 00 01 00 01 22 01 3e 01 | ce 00 05 a1 00 b6 00 04 |....".>.|........|
|00000810| 00 01 00 01 07 00 00 00 | 00 23 00 00 a0 00 8c a1 |........|.#......|
|00000820| 00 96 00 0c 01 00 00 00 | 02 00 00 00 00 00 00 00 |........|........|
|00000830| a1 00 9a 00 08 ff fe 00 | 00 00 0a 00 00 01 00 0a |........|........|
|00000840| 01 71 01 88 01 78 01 9f | 04 00 28 01 76 01 89 06 |.q...x..|..(.v...|
|00000850| 43 45 52 20 23 31 a0 00 | 97 a1 00 b6 00 04 00 20 |CER #1..|....... |
|00000860| 00 80 01 00 0a 01 08 01 | 7a 01 94 02 34 07 00 01 |........|z...4...|
|00000870| 00 01 30 01 6e 01 83 01 | 7b 01 9f a1 00 b6 00 04 |..0.n...|{.......|
|00000880| 00 01 00 01 07 00 00 00 | 00 22 01 76 01 9c 00 00 |........|.".v....|
|00000890| a1 00 96 00 0c 01 00 00 | 00 02 00 00 00 00 00 00 |........|........|
|000008a0| 00 a1 00 9a 00 08 ff fe | 00 00 00 0a 00 00 01 00 |........|........|
|000008b0| 0a 01 71 01 b9 01 78 01 | d0 29 31 06 43 45 52 20 |..q...x.|.)1.CER |
|000008c0| 23 32 a0 00 97 a1 00 b6 | 00 04 00 20 00 80 01 00 |#2......|... ....|
|000008d0| 0a 01 08 01 7a 01 94 02 | 34 07 00 01 00 01 30 01 |....z...|4.....0.|
|000008e0| 6e 01 b4 01 7b 01 d0 a1 | 00 b6 00 04 00 01 00 01 |n...{...|........|
|000008f0| 07 00 00 00 00 22 01 76 | 01 cd 00 00 a1 00 96 00 |.....".v|........|
|00000900| 0c 01 00 00 00 02 00 00 | 00 00 00 00 00 a1 00 9a |........|........|
|00000910| 00 08 ff fe 00 00 00 0a | 00 00 01 00 0a 01 71 01 |........|......q.|
|00000920| fe 01 78 02 15 29 45 06 | 43 45 52 20 23 33 a0 00 |..x..)E.|CER #3..|
|00000930| 97 a1 00 b6 00 04 00 20 | 00 80 01 00 0a 01 08 01 |....... |........|
|00000940| 7a 01 94 02 34 07 00 01 | 00 01 30 01 6e 01 f9 01 |z...4...|..0.n...|
|00000950| 7b 02 15 a1 00 b6 00 04 | 00 01 00 01 07 00 00 00 |{.......|........|
|00000960| 00 22 01 76 02 12 00 00 | a1 00 96 00 0c 01 00 00 |.".v....|........|
|00000970| 00 02 00 00 00 00 00 00 | 00 a1 00 9a 00 08 ff fe |........|........|
|00000980| 00 00 00 09 00 00 01 00 | 0a 01 89 01 f9 01 90 02 |........|........|
|00000990| 0e 28 01 8e 01 fa 06 44 | 65 6c 54 6f 6b a0 00 97 |.(.....D|elTok...|
|000009a0| a1 00 b6 00 04 00 20 00 | 80 01 00 0a 01 08 01 7a |...... .|.......z|
|000009b0| 01 94 02 34 07 00 01 00 | 01 30 01 87 01 f3 01 91 |...4....|.0......|
|000009c0| 02 14 a1 00 b6 00 04 00 | 01 00 01 07 00 00 00 00 |........|........|
|000009d0| 22 01 8e 02 0c 00 00 a1 | 00 96 00 0c 01 00 00 00 |".......|........|
|000009e0| 02 00 00 00 00 00 00 00 | a1 00 9a 00 08 ff fd 00 |........|........|
|000009f0| 00 00 08 00 00 01 00 0a | 01 88 01 d3 01 8e 01 e6 |........|........|
|00000a00| 28 01 8d 01 d4 05 57 72 | 54 6f 6b a0 00 97 a1 00 |(.....Wr|Tok.....|
|00000a10| b6 00 04 00 20 00 80 01 | 00 0a 01 08 01 7a 01 94 |.... ...|.....z..|
|00000a20| 02 34 07 00 01 00 01 30 | 01 86 01 cd 01 90 01 ee |.4.....0|........|
|00000a30| a1 00 b6 00 04 00 01 00 | 01 07 00 00 00 00 22 01 |........|......".|
|00000a40| 8d 01 e5 00 00 a1 00 96 | 00 0c 01 00 00 00 02 00 |........|........|
|00000a50| 00 00 00 00 00 00 a1 00 | 9a 00 08 ff fd 00 00 00 |........|........|
|00000a60| 08 00 00 01 00 0a 01 88 | 01 af 01 8e 01 c2 28 01 |........|......(.|
|00000a70| 8d 01 b0 05 52 64 54 6f | 6b a0 00 97 a1 00 b6 00 |....RdTo|k.......|
|00000a80| 04 00 20 00 80 01 00 0a | 01 08 01 7a 01 94 02 34 |.. .....|...z...4|
|00000a90| 07 00 01 00 01 30 01 86 | 01 a8 01 90 01 c9 a1 00 |.....0..|........|
|00000aa0| b6 00 04 00 01 00 01 07 | 00 00 00 00 22 01 8d 01 |........|...."...|
|00000ab0| c1 00 00 a1 00 96 00 0c | 01 00 00 00 02 00 00 00 |........|........|
|00000ac0| 00 00 00 00 a1 00 9a 00 | 08 ff fd 00 00 00 09 00 |........|........|
|00000ad0| 00 01 00 0a 01 88 01 89 | 01 8e 01 9e 28 01 8d 01 |........|....(...|
|00000ae0| 8a 06 49 6e 73 54 6f 6b | a0 00 97 a1 00 b6 00 04 |..InsTok|........|
|00000af0| 00 20 00 80 01 00 0a 01 | 08 01 7a 01 94 02 34 07 |. ......|..z...4.|
|00000b00| 00 01 00 01 30 01 86 01 | 83 01 90 01 a3 a1 00 b6 |....0...|........|
|00000b10| 00 04 00 01 00 01 07 00 | 00 00 00 22 01 8d 01 9b |........|..."....|
|00000b20| 00 00 a1 00 96 00 0c 01 | 00 00 00 02 00 00 00 00 |........|........|
|00000b30| 00 00 00 a1 00 9a 00 08 | ff fd 00 00 00 12 00 00 |........|........|
|00000b40| 01 00 0a 01 5a 01 bf 01 | 60 01 e6 28 01 5f 01 c0 |....Z...|`..(._..|
|00000b50| 08 43 6d 64 53 77 63 68 | 72 a0 00 97 a1 00 b6 00 |.CmdSwch|r.......|
|00000b60| 04 00 20 00 80 01 00 0a | 01 08 01 7a 01 94 02 34 |.. .....|...z...4|
|00000b70| 07 00 01 00 01 30 01 58 | 01 b0 01 62 01 f0 a1 00 |.....0.X|...b....|
|00000b80| b6 00 04 00 01 00 01 07 | 00 00 00 00 22 01 5f 01 |........|...."._.|
|00000b90| db 00 00 a1 00 b6 00 04 | 00 20 00 80 07 00 01 00 |........|. ......|
|00000ba0| 01 22 01 61 01 c3 d7 0d | a1 00 b6 00 04 00 01 00 |.".a....|........|
|00000bb0| 01 07 00 00 00 00 23 00 | 00 a1 00 b6 00 04 00 20 |......#.|....... |
|00000bc0| 00 80 07 00 01 00 01 22 | 01 62 01 d4 f3 0c a1 00 |......."|.b......|
|00000bd0| b6 00 04 00 01 00 01 07 | 00 00 00 00 23 00 00 a1 |........|....#...|
|00000be0| 00 b6 00 04 00 20 00 80 | 07 00 01 00 01 22 01 62 |..... ..|.....".b|
|00000bf0| 01 e0 26 0c a1 00 b6 00 | 04 00 01 00 01 07 00 00 |..&.....|........|
|00000c00| 00 00 23 00 00 a1 00 b6 | 00 04 00 20 00 80 07 00 |..#.....|... ....|
|00000c10| 01 00 01 22 01 7a 01 90 | 00 0c a1 00 b6 00 04 00 |...".z..|........|
|00000c20| 01 00 01 07 00 00 00 00 | 23 00 00 a1 00 b6 00 04 |........|#.......|
|00000c30| 00 20 00 80 07 00 01 00 | 01 22 01 7b 01 c2 d7 0b |. ......|.".{....|
|00000c40| a1 00 b6 00 04 00 01 00 | 01 07 00 00 00 00 23 00 |........|......#.|
|00000c50| 00 a0 00 8c a1 00 b6 00 | 04 00 20 00 80 51 01 73 |........|.. ..Q.s|
|00000c60| 01 e1 01 75 01 e3 07 00 | 01 00 01 58 a1 00 b6 00 |...u....|...X....|
|00000c70| 04 00 01 00 01 07 00 00 | 00 00 23 00 00 a1 00 b6 |........|..#.....|
|00000c80| 00 04 00 20 00 80 51 01 | 73 01 e5 01 75 01 e7 07 |... ..Q.|s...u...|
|00000c90| 00 01 00 01 58 a1 00 b6 | 00 04 00 01 00 01 07 00 |....X...|........|
|00000ca0| 00 00 00 23 00 00 a1 00 | b6 00 04 00 20 00 80 51 |...#....|.... ..Q|
|00000cb0| 01 73 01 ea 01 75 01 ec | 07 00 01 00 01 58 a1 00 |.s...u..|.....X..|
|00000cc0| b6 00 04 00 01 00 01 07 | 00 00 00 00 23 00 00 a0 |........|....#...|
|00000cd0| 00 8d a1 00 b6 00 04 00 | 20 00 80 07 00 01 00 01 |........| .......|
|00000ce0| 30 01 53 01 7f 01 94 02 | 1b a1 00 b6 00 04 00 01 |0.S.....|........|
|00000cf0| 00 01 07 00 00 00 00 23 | 00 00 a1 00 b6 00 04 00 |.......#|........|
|00000d00| 20 00 80 07 00 01 00 01 | 22 01 7a 01 9b 1d 0c a1 | .......|".z.....|
|00000d10| 00 b6 00 04 00 01 00 01 | 07 00 00 00 00 23 00 00 |........|.....#..|
|00000d20| a1 00 b6 00 04 00 20 00 | 80 07 00 01 00 01 22 01 |...... .|......".|
|00000d30| 7a 01 c8 0f 0c a1 00 b6 | 00 04 00 01 00 01 07 00 |z.......|........|
|00000d40| 00 00 00 23 00 00 a1 00 | b6 00 04 00 20 00 80 07 |...#....|.... ...|
|00000d50| 00 01 00 01 22 01 7a 02 | 02 bf 0c a1 00 b6 00 04 |....".z.|........|
|00000d60| 00 01 00 01 07 00 00 00 | 00 23 00 00 a1 00 b6 00 |........|.#......|
|00000d70| 04 00 20 00 80 07 00 01 | 00 01 22 01 7a 02 08 00 |.. .....|..".z...|
|00000d80| 0d a1 00 b6 00 04 00 01 | 00 01 07 00 00 00 00 23 |........|.......#|
|00000d90| 00 00 a1 00 b6 00 04 00 | 20 00 80 07 00 01 00 01 |........| .......|
|00000da0| 22 01 7a 02 02 e1 0c a1 | 00 b6 00 04 00 01 00 01 |".z.....|........|
|00000db0| 07 00 00 00 00 23 00 00 | a0 00 8d a0 00 8c a1 00 |.....#..|........|
|00000dc0| 96 00 0c 01 00 00 00 02 | 00 00 00 00 00 00 00 a1 |........|........|
|00000dd0| 00 9a 00 08 ff fe 00 00 | 00 0b 00 00 01 00 0a 01 |........|........|
|00000de0| 59 01 88 01 60 01 a1 28 | 01 5e 01 89 09 61 63 63 |Y...`..(|.^...acc|
|00000df0| 65 73 73 6f 72 73 a0 00 | 97 a1 00 b6 00 04 00 20 |essors..|....... |
|00000e00| 00 80 01 00 0a 01 08 01 | 7a 01 94 02 34 07 00 01 |........|z...4...|
|00000e10| 00 01 30 01 57 01 85 01 | 62 01 a2 a1 00 b6 00 04 |..0.W...|b.......|
|00000e20| 00 01 00 01 07 00 00 00 | 00 22 01 5e 01 a0 00 00 |........|.".^....|
|00000e30| a0 00 8d a1 00 b6 00 04 | 00 20 00 80 07 00 01 00 |........|. ......|
|00000e40| 01 09 aa 55 aa 55 aa 55 | aa 55 22 01 3e 01 b1 df |...U.U.U|.U".>...|
|00000e50| 1a a1 00 b6 00 04 00 01 | 00 01 07 00 00 00 00 23 |........|.......#|
|00000e60| 00 00 a0 00 8d a1 00 b6 | 00 04 00 20 00 80 a1 00 |........|... ....|
|00000e70| b6 00 04 00 01 00 01 23 | 00 00 a1 00 b6 00 04 00 |.......#|........|
|00000e80| 20 00 80 a1 00 b6 00 04 | 00 01 00 01 23 00 00 a1 | .......|....#...|
|00000e90| 00 b6 00 04 00 20 00 80 | a1 00 b6 00 04 00 01 00 |..... ..|........|
|00000ea0| 01 23 00 00 a1 00 b6 00 | 04 00 20 00 80 a1 00 b6 |.#......|.. .....|
|00000eb0| 00 04 00 01 00 01 23 00 | 00 a1 00 b6 00 04 00 20 |......#.|....... |
|00000ec0| 00 80 a1 00 b6 00 04 00 | 01 00 01 23 00 00 a1 00 |........|...#....|
|00000ed0| b6 00 04 00 20 00 80 a1 | 00 b6 00 04 00 01 00 01 |.... ...|........|
|00000ee0| 23 00 00 a1 00 b6 00 04 | 00 20 00 80 a1 00 b6 00 |#.......|. ......|
|00000ef0| 04 00 01 00 01 23 00 00 | a1 00 b6 00 04 00 20 00 |.....#..|...... .|
|00000f00| 80 a1 00 b6 00 04 00 01 | 00 01 23 00 00 a1 00 b6 |........|..#.....|
|00000f10| 00 04 00 20 00 80 a1 00 | b6 00 04 00 01 00 01 23 |... ....|.......#|
|00000f20| 00 00 a1 00 b6 00 04 00 | 20 00 80 a1 00 b6 00 04 |........| .......|
|00000f30| 00 01 00 01 23 00 00 a1 | 00 b6 00 04 00 20 00 80 |....#...|..... ..|
|00000f40| a1 00 b6 00 04 00 01 00 | 01 23 00 00 a1 00 b6 00 |........|.#......|
|00000f50| 04 00 20 00 80 a1 00 b6 | 00 04 00 01 00 01 23 00 |.. .....|......#.|
|00000f60| 00 a1 00 b6 00 04 00 20 | 00 80 a1 00 b6 00 04 00 |....... |........|
|00000f70| 01 00 01 23 00 00 a1 00 | b6 00 04 00 20 00 80 a1 |...#....|.... ...|
|00000f80| 00 b6 00 04 00 01 00 01 | 23 00 00 a1 00 b6 00 04 |........|#.......|
|00000f90| 00 20 00 80 a1 00 b6 00 | 04 00 01 00 01 23 00 00 |. ......|.....#..|
|00000fa0| a1 00 b6 00 04 00 20 00 | 80 a1 00 b6 00 04 00 01 |...... .|........|
|00000fb0| 00 01 23 00 00 a1 00 b6 | 00 04 00 20 00 80 a1 00 |..#.....|... ....|
|00000fc0| b6 00 04 00 01 00 01 23 | 00 00 a1 00 b6 00 04 00 |.......#|........|
|00000fd0| 20 00 80 a1 00 b6 00 04 | 00 01 00 01 23 00 00 a1 | .......|....#...|
|00000fe0| 00 b6 00 04 00 20 00 80 | a1 00 b6 00 04 00 01 00 |..... ..|........|
|00000ff0| 01 23 00 00 a1 00 b6 00 | 04 00 20 00 80 a1 00 b6 |.#......|.. .....|
|00001000| 00 04 00 01 00 01 23 00 | 00 a1 00 b6 00 04 00 20 |......#.|....... |
|00001010| 00 80 a1 00 b6 00 04 00 | 01 00 01 23 00 00 a1 00 |........|...#....|
|00001020| b6 00 04 00 20 00 80 a1 | 00 b6 00 04 00 01 00 01 |.... ...|........|
|00001030| 23 00 00 a1 00 b6 00 04 | 00 20 00 80 a1 00 b6 00 |#.......|. ......|
|00001040| 04 00 01 00 01 23 00 00 | a1 00 b6 00 04 00 20 00 |.....#..|...... .|
|00001050| 80 a1 00 b6 00 04 00 01 | 00 01 23 00 00 a1 00 b6 |........|..#.....|
|00001060| 00 04 00 20 00 80 a1 00 | b6 00 04 00 01 00 01 23 |... ....|.......#|
|00001070| 00 00 a1 00 b6 00 04 00 | 20 00 80 a1 00 b6 00 04 |........| .......|
|00001080| 00 01 00 01 23 00 00 a1 | 00 b6 00 04 00 20 00 80 |....#...|..... ..|
|00001090| a1 00 b6 00 04 00 01 00 | 01 23 00 00 a1 00 b6 00 |........|.#......|
|000010a0| 04 00 20 00 80 a1 00 b6 | 00 04 00 01 00 01 23 00 |.. .....|......#.|
|000010b0| 00 a1 00 b6 00 04 00 20 | 00 80 a1 00 b6 00 04 00 |....... |........|
|000010c0| 01 00 01 23 00 00 a1 00 | b6 00 04 00 20 00 80 a1 |...#....|.... ...|
|000010d0| 00 b6 00 04 00 01 00 01 | 23 00 00 a1 00 b6 00 04 |........|#.......|
|000010e0| 00 20 00 80 a1 00 b6 00 | 04 00 01 00 01 23 00 00 |. ......|.....#..|
|000010f0| a1 00 b6 00 04 00 20 00 | 80 a1 00 b6 00 04 00 01 |...... .|........|
|00001100| 00 01 23 00 00 a1 00 b6 | 00 04 00 20 00 80 a1 00 |..#.....|... ....|
|00001110| b6 00 04 00 01 00 01 23 | 00 00 a1 00 b6 00 04 00 |.......#|........|
|00001120| 20 00 80 a1 00 b6 00 04 | 00 01 00 01 23 00 00 a1 | .......|....#...|
|00001130| 00 b6 00 04 00 20 00 80 | a1 00 b6 00 04 00 01 00 |..... ..|........|
|00001140| 01 23 00 00 a1 00 b6 00 | 04 00 20 00 80 a1 00 b6 |.#......|.. .....|
|00001150| 00 04 00 01 00 01 23 00 | 00 a1 00 b6 00 04 00 20 |......#.|....... |
|00001160| 00 80 a1 00 b6 00 04 00 | 01 00 01 23 00 00 a1 00 |........|...#....|
|00001170| b6 00 04 00 20 00 80 a1 | 00 b6 00 04 00 01 00 01 |.... ...|........|
|00001180| 23 00 00 a1 00 b6 00 04 | 00 20 00 80 a1 00 b6 00 |#.......|. ......|
|00001190| 04 00 01 00 01 23 00 00 | a1 00 b6 00 04 00 20 00 |.....#..|...... .|
|000011a0| 80 a1 00 b6 00 04 00 01 | 00 01 23 00 00 a0 00 83 |........|..#.....|
|000011b0| 01 00 0a 00 00 00 00 03 | 15 02 5f 04 01 0d 00 0e |........|.._.....|
|000011c0| 2e 00 04 00 00 00 00 10 | 00 01 00 01 00 01 00 01 |........|........|
|000011d0| 28 01 14 00 48 0b 57 68 | 61 74 20 74 6f 20 55 73 |(...H.Wh|at to Us|
|000011e0| 65 04 00 0d 00 0c 2b 24 | 12 14 53 6f 75 72 63 65 |e.....+$|..Source|
|000011f0| 20 43 6f 64 65 20 46 69 | 6c 65 28 73 29 3a 29 6c | Code Fi|le(s):)l|
|00001200| 11 6c 61 62 5f 52 65 67 | 69 73 74 72 79 5f 44 31 |.lab_Reg|istry_D1|
|00001210| 2e 63 28 01 38 00 6c 0e | 53 6f 6c 75 74 69 6f 6e |.c(.8.l.|Solution|
|00001220| 20 66 69 6c 65 3a 29 6c | 35 6c 61 62 5f 52 65 67 | file:)l|5lab_Reg|
|00001230| 69 73 74 72 79 5f 44 31 | 2e 73 6f 6c 6e 2e 63 20 |istry_D1|.soln.c |
|00001240| 28 69 6e 20 74 68 65 20 | d2 28 73 6f 6c 75 74 69 |(in the |.(soluti|
|00001250| 6f 6e 73 29 d3 20 66 6f | 6c 64 65 72 2e 29 28 01 |ons). fo|lder.)(.|
|00001260| 4a 00 6c 0e 48 6f 6f 6b | 20 72 6f 75 74 69 6e 65 |J.l.Hook| routine|
|00001270| 73 3a 29 6c 1b 6c 61 62 | 5f 49 6e 73 74 61 6c 6c |s:)l.lab|_Install|
|00001280| 41 45 4f 62 6a 65 63 74 | 44 69 73 70 61 74 63 68 |AEObject|Dispatch|
|00001290| 2a 0c 17 6c 61 62 5f 44 | 69 72 65 63 74 50 61 72 |*..lab_D|irectPar|
|000012a0| 61 6d 44 69 73 70 61 74 | 63 68 2a 0c 19 6c 61 62 |amDispat|ch*..lab|
|000012b0| 5f 43 72 65 61 74 65 45 | 6c 65 6d 65 6e 74 44 69 |_CreateE|lementDi|
|000012c0| 73 70 61 74 63 68 04 02 | 28 01 6e 00 48 0a 28 6f |spatch..|(.n.H.(o|
|000012d0| 70 74 69 6f 6e 61 6c 29 | 04 00 2b 90 0c 12 6c 61 |ptional)|..+...la|
|000012e0| 62 5f 53 65 6e 64 41 45 | 54 6f 4f 62 6a 65 63 74 |b_SendAE|ToObject|
|000012f0| 04 01 0d 00 0e 28 01 c1 | 00 48 08 53 79 6e 6f 70 |.....(..|.H.Synop|
|00001300| 73 69 73 04 00 0d 00 0c | 2a 18 5c 54 68 69 73 20 |sis.....|*.\This |
|00001310| 6c 61 62 20 69 73 20 74 | 68 65 20 66 69 72 73 74 |lab is t|he first|
|00001320| 20 6f 66 20 66 69 76 65 | 20 6c 61 62 73 20 69 6e | of five| labs in|
|00001330| 76 6f 6c 76 69 6e 67 20 | 74 68 65 20 63 6f 6d 70 |volving |the comp|
|00001340| 6c 65 74 65 20 69 6d 70 | 6c 65 6d 65 6e 74 61 74 |lete imp|lementat|
|00001350| 69 6f 6e 20 6f 66 20 74 | 68 65 20 63 41 70 70 6f |ion of t|he cAppo|
|00001360| 69 6e 74 6d 65 6e 74 2a | 0c 59 41 70 70 6c 65 20 |intment*|.YApple |
|00001370| 45 76 65 6e 74 20 6f 62 | 6a 65 63 74 2e 20 20 54 |Event ob|ject. T|
|00001380| 68 65 20 63 41 70 70 6f | 69 6e 74 6d 65 6e 74 20 |he cAppo|intment |
|00001390| 6f 62 6a 65 63 74 20 63 | 6f 6e 74 61 69 6e 73 20 |object c|ontains |
|000013a0| 74 68 65 20 69 6e 66 6f | 72 6d 61 74 69 6f 6e 20 |the info|rmation |
|000013b0| 61 6e 64 20 64 61 74 61 | 20 61 73 73 6f 63 69 61 |and data| associa|
|000013c0| 74 65 64 2a 0c 32 77 69 | 74 68 20 61 20 73 69 6e |ted*.2wi|th a sin|
|000013d0| 67 6c 65 20 61 70 70 6f | 69 6e 74 6d 65 6e 74 20 |gle appo|intment |
|000013e0| 69 6e 20 74 68 65 20 63 | 61 6c 65 6e 64 61 72 20 |in the c|alendar |
|000013f0| 70 72 6f 67 72 61 6d 2e | 2a 18 40 54 68 65 20 4f |program.|*.@The O|
|00001400| 53 4c 20 6c 61 62 73 20 | 68 61 64 20 79 6f 75 20 |SL labs |had you |
|00001410| 69 6d 70 6c 65 6d 65 6e | 74 20 74 68 65 20 63 6f |implemen|t the co|
|00001420| 64 65 20 74 6f 20 72 65 | 73 6f 6c 76 65 20 63 41 |de to re|solve cA|
|00001430| 70 70 6f 69 6e 74 6d 65 | 6e 74 20 04 04 28 02 09 |ppointme|nt ..(..|
|00001440| 01 89 11 6f 62 6a 65 63 | 74 20 73 70 65 63 69 66 |...objec|t specif|
|00001450| 69 65 72 73 04 00 29 4c | 0d 2e 20 20 54 68 65 20 |iers..)L|.. The |
|00001460| 6f 62 6a 65 63 74 28 02 | 15 00 48 60 73 70 65 63 |object(.|..H`spec|
|00001470| 69 66 69 65 72 20 72 65 | 73 6f 6c 75 74 69 6f 6e |ifier re|solution|
|00001480| 20 70 72 6f 63 65 73 73 | 20 69 73 20 6f 6e 65 20 | process| is one |
|00001490| 70 61 72 74 20 6f 66 20 | 69 6d 70 6c 65 6d 65 6e |part of |implemen|
|000014a0| 74 69 6e 67 20 61 20 52 | 65 67 69 73 74 72 79 20 |ting a R|egistry |
|000014b0| 65 76 65 6e 74 20 68 61 | 6e 64 6c 65 72 2e 20 48 |event ha|ndler. H|
|000014c0| 6f 77 65 76 65 72 2c 20 | 74 68 69 73 2a 0c 5d 6f |owever, |this*.]o|
|000014d0| 6e 6c 79 20 68 65 6c 70 | 73 20 79 6f 75 20 77 69 |nly help|s you wi|
|000014e0| 74 68 20 74 68 65 20 64 | 69 72 65 63 74 20 6f 62 |th the d|irect ob|
|000014f0| 6a 65 63 74 20 d1 ca 74 | 68 65 20 4f 53 4c 20 6c |ject ..t|he OSL l|
|00001500| 61 62 73 20 64 69 64 20 | 6e 6f 74 68 69 6e 67 20 |abs did |nothing |
|00001510| 74 6f 20 68 65 6c 70 20 | 79 6f 75 20 69 6d 70 6c |to help |you impl|
|00001520| 65 6d 65 6e 74 20 61 6e | 79 20 6f 66 2a 0c 10 74 |ement an|y of*..t|
|00001530| 68 65 20 43 6f 72 65 20 | 65 76 65 6e 74 73 2e 2a |he Core |events.*|
|00001540| 18 5c 41 73 20 64 69 73 | 63 75 73 73 65 64 20 69 |.\As dis|cussed i|
|00001550| 6e 20 74 68 65 20 65 76 | 65 6e 74 20 68 61 6e 64 |n the ev|ent hand|
|00001560| 6c 65 72 20 61 72 63 68 | 69 74 65 63 74 75 72 65 |ler arch|itecture|
|00001570| 20 6d 6f 64 75 6c 65 73 | 2c 20 74 68 65 72 65 20 | modules|, there |
|00001580| 61 72 65 20 73 65 76 65 | 72 61 6c 20 67 65 6e 65 |are seve|ral gene|
|00001590| 72 69 63 20 70 61 72 74 | 73 20 74 6f 20 61 2a 0c |ric part|s to a*.|
|000015a0| 61 52 65 67 69 73 74 72 | 79 20 65 76 65 6e 74 20 |aRegistr|y event |
|000015b0| 68 61 6e 64 6c 65 72 2c | 20 69 6e 63 6c 75 64 69 |handler,| includi|
|000015c0| 6e 67 20 74 68 65 20 63 | 6f 64 65 20 74 6f 20 73 |ng the c|ode to s|
|000015d0| 65 6c 65 63 74 20 74 68 | 65 20 70 72 6f 70 65 72 |elect th|e proper|
|000015e0| 20 72 75 6e 2d 74 69 6d | 65 20 72 6f 75 74 69 6e | run-tim|e routin|
|000015f0| 65 20 66 6f 72 20 61 20 | 70 61 72 74 69 63 75 6c |e for a |particul|
|00001600| 61 72 2a 0c 61 65 76 65 | 6e 74 20 61 6e 64 20 74 |ar*.aeve|nt and t|
|00001610| 68 65 20 63 6f 64 65 20 | 74 6f 20 65 78 65 63 75 |he code |to execu|
|00001620| 74 65 20 74 68 65 20 72 | 65 71 75 65 73 74 65 64 |te the r|equested|
|00001630| 20 61 63 74 69 6f 6e 2e | 20 59 6f 75 20 77 69 6c | action.| You wil|
|00001640| 6c 20 69 6d 70 6c 65 6d | 65 6e 74 20 74 68 65 73 |l implem|ent thes|
|00001650| 65 20 6f 74 68 65 72 20 | 70 61 72 74 73 20 69 6e |e other |parts in|
|00001660| 20 74 68 65 73 65 2a 0c | 0e 52 65 67 69 73 74 72 | these*.|.Registr|
|00001670| 79 20 6c 61 62 73 2e 2a | 18 5c 54 68 69 73 20 6c |y labs.*|.\This l|
|00001680| 61 62 20 28 52 65 67 69 | 73 74 72 79 20 2f 20 44 |ab (Regi|stry / D|
|00001690| 31 29 20 68 61 73 20 79 | 6f 75 20 69 6d 70 6c 65 |1) has y|ou imple|
|000016a0| 6d 65 6e 74 20 74 68 65 | 20 4f 62 6a 65 63 74 20 |ment the| Object |
|000016b0| 44 69 73 70 61 74 63 68 | 65 72 20 63 6f 64 65 2c |Dispatch|er code,|
|000016c0| 20 61 73 20 68 69 67 68 | 6c 69 67 68 74 65 64 20 | as high|lighted |
|000016d0| 69 6e 20 74 68 65 2a 0c | 5a 64 69 61 67 72 61 6d |in the*.|Zdiagram|
|000016e0| 20 61 62 6f 76 65 2e 20 | 54 68 65 20 6e 65 78 74 | above. |The next|
|000016f0| 20 73 65 74 20 6f 66 20 | 6c 61 62 73 2c 20 52 65 | set of |labs, Re|
|00001700| 67 69 73 74 72 79 20 2f | 20 44 32 20 70 61 72 74 |gistry /| D2 part|
|00001710| 73 20 31 20 74 68 72 6f | 75 67 68 20 34 2c 20 68 |s 1 thro|ugh 4, h|
|00001720| 65 6c 70 20 79 6f 75 20 | 69 6d 70 6c 65 6d 65 6e |elp you |implemen|
|00001730| 74 20 34 2a 0c 5a 73 70 | 65 63 69 66 69 63 20 65 |t 4*.Zsp|ecific e|
|00001740| 76 65 6e 74 73 20 d1 ca | 47 65 74 20 44 61 74 61 |vents ..|Get Data|
|00001750| 2c 20 53 65 74 20 44 61 | 74 61 2c 20 44 65 6c 65 |, Set Da|ta, Dele|
|00001760| 74 65 20 45 6c 65 6d 65 | 6e 74 2c 20 61 6e 64 20 |te Eleme|nt, and |
|00001770| 43 72 65 61 74 65 20 45 | 6c 65 6d 65 6e 74 20 d1 |Create E|lement .|
|00001780| 20 61 73 20 61 70 70 6c | 69 65 64 20 74 6f 20 61 | as appl|ied to a|
|00001790| 2a 0c 14 63 41 70 70 6f | 69 6e 74 6d 65 6e 74 20 |*..cAppo|intment |
|000017a0| 6f 62 6a 65 63 74 2e 2a | 18 5d 59 6f 75 20 77 69 |object.*|.]You wi|
|000017b0| 6c 6c 20 69 6d 70 6c 65 | 6d 65 6e 74 20 61 72 6f |ll imple|ment aro|
|000017c0| 75 6e 64 20 61 20 64 6f | 7a 65 6e 20 72 6f 75 74 |und a do|zen rout|
|000017d0| 69 6e 65 73 20 77 69 74 | 68 69 6e 20 74 68 65 73 |ines wit|hin thes|
|000017e0| 65 20 66 69 76 65 20 6c | 61 62 73 2e 20 53 69 6e |e five l|abs. Sin|
|000017f0| 63 65 20 74 69 6d 65 20 | 69 73 20 6c 69 6d 69 74 |ce time |is limit|
|00001800| 65 64 2c 20 6f 75 72 2a | 0c 61 69 6e 73 74 72 75 |ed, our*|.ainstru|
|00001810| 63 74 69 6f 6e 73 20 77 | 69 6c 6c 20 62 65 20 66 |ctions w|ill be f|
|00001820| 61 69 72 6c 79 20 65 78 | 70 6c 69 63 69 74 20 d1 |airly ex|plicit .|
|00001830| 20 77 65 20 77 69 6c 6c | 20 67 69 76 65 20 79 6f | we will| give yo|
|00001840| 75 20 61 20 d2 72 65 63 | 69 70 65 d3 20 66 6f 72 |u a .rec|ipe. for|
|00001850| 20 69 6d 70 6c 65 6d 65 | 6e 74 69 6e 67 20 65 61 | impleme|nting ea|
|00001860| 63 68 20 72 6f 75 74 69 | 6e 65 2c 2a 25 14 44 65 |ch routi|ne,*%.De|
|00001870| 76 65 6c 6f 70 65 72 20 | 55 6e 69 76 65 72 73 69 |veloper |Universi|
|00001880| 74 79 29 e0 02 2d 20 29 | 07 01 31 29 06 02 20 2d |ty)..- )|..1).. -|
|00001890| 29 95 18 52 65 67 69 73 | 74 72 79 20 2f 20 44 31 |)..Regis|try / D1|
|000018a0| 20 20 4c 61 62 20 4e 6f | 74 65 73 ff 00 0c 00 00 | Lab No|tes.....|
|000018b0| 00 00 02 d7 02 23 11 01 | 0c 00 1e 00 1f 01 00 0a |.....#..|........|
|000018c0| 00 00 00 00 03 15 02 5f | 2c 00 08 00 14 05 54 69 |......._|,.....Ti|
|000018d0| 6d 65 73 03 00 14 0d 00 | 0c 2e 00 04 00 00 00 00 |mes.....|........|
|000018e0| 2b 48 2e 54 64 65 66 69 | 6e 65 20 74 68 65 20 63 |+H.Tdefi|ne the c|
|000018f0| 61 6c 6c 69 6e 67 20 73 | 65 71 75 65 6e 63 65 20 |alling s|equence |
|00001900| 66 6f 72 20 65 61 63 68 | 20 72 6f 75 74 69 6e 65 |for each| routine|
|00001910| 2c 20 61 6e 64 20 67 69 | 76 65 20 79 6f 75 20 61 |, and gi|ve you a|
|00001920| 20 73 65 74 20 6f 66 20 | 73 75 70 70 6f 72 74 20 | set of |support |
|00001930| 72 6f 75 74 69 6e 65 73 | 0d 00 09 28 00 2b 01 cc |routines|...(.+..|
|00001940| 01 31 0d 00 0c 2b 05 03 | 0e 2e 20 49 74 20 77 69 |.1...+..|.. It wi|
|00001950| 6c 6c 20 74 68 65 6e 28 | 00 3a 00 48 32 62 65 20 |ll then(|.:.H2be |
|00001960| 75 70 20 74 6f 20 79 6f | 75 20 74 6f 20 69 6d 70 |up to yo|u to imp|
|00001970| 6c 65 6d 65 6e 74 20 74 | 68 65 20 62 6f 64 79 20 |lement t|he body |
|00001980| 6f 66 20 65 61 63 68 20 | 68 6f 6f 6b 2e 20 20 04 |of each |hook. .|
|00001990| 02 29 f1 2b 49 66 20 79 | 6f 75 20 77 61 6e 74 20 |.).+If y|ou want |
|000019a0| 74 6f 20 63 6f 6d 70 6c | 65 74 65 20 74 68 65 20 |to compl|ete the |
|000019b0| 6c 61 62 73 20 77 69 74 | 68 69 6e 20 74 68 65 28 |labs wit|hin the(|
|000019c0| 00 46 00 48 3e 61 76 61 | 69 6c 61 62 6c 65 20 74 |.F.H>ava|ilable t|
|000019d0| 69 6d 65 2c 20 79 6f 75 | 20 77 69 6c 6c 20 6e 65 |ime, you| will ne|
|000019e0| 65 64 20 74 6f 20 66 6f | 6c 6c 6f 77 20 74 68 65 |ed to fo|llow the|
|000019f0| 20 4c 61 62 20 4e 6f 74 | 65 73 20 63 6c 6f 73 65 | Lab Not|es close|
|00001a00| 6c 79 2e 04 00 2a 18 34 | 49 6e 20 74 68 69 73 20 |ly...*.4|In this |
|00001a10| 6c 61 62 20 79 6f 75 20 | 77 69 6c 6c 20 69 6d 70 |lab you |will imp|
|00001a20| 6c 65 6d 65 6e 74 20 74 | 77 6f 20 6d 61 6a 6f 72 |lement t|wo major|
|00001a30| 20 72 6f 75 74 69 6e 65 | 73 20 d1 20 04 01 29 fb | routine|s . ..).|
|00001a40| 17 6c 61 62 5f 44 69 72 | 65 63 74 50 61 72 61 6d |.lab_Dir|ectParam|
|00001a50| 44 69 73 70 61 74 63 68 | 04 00 29 8e 04 20 61 6e |Dispatch|..).. an|
|00001a60| 64 04 01 28 00 6a 00 48 | 12 6c 61 62 5f 53 65 6e |d..(.j.H|.lab_Sen|
|00001a70| 64 41 45 54 6f 4f 62 6a | 65 63 74 04 00 29 78 23 |dAEToObj|ect..)x#|
|00001a80| 20 20 d1 20 61 6e 64 20 | 61 20 73 6d 61 6c 6c 20 | . and |a small |
|00001a90| 72 6f 75 74 69 6e 65 20 | 74 6f 20 69 6e 73 74 61 |routine |to insta|
|00001aa0| 6c 6c 20 04 01 29 9c 17 | 6c 61 62 5f 44 69 72 65 |ll ..)..|lab_Dire|
|00001ab0| 63 74 50 61 72 61 6d 44 | 69 73 70 61 74 63 68 04 |ctParamD|ispatch.|
|00001ac0| 00 29 8e 05 20 69 6e 74 | 6f 28 00 76 00 48 2a 74 |.).. int|o(.v.H*t|
|00001ad0| 68 65 20 41 70 70 6c 65 | 20 45 76 65 6e 74 20 4d |he Apple| Event M|
|00001ae0| 61 6e 61 67 65 72 d5 73 | 20 64 69 73 70 61 74 63 |anager.s| dispatc|
|00001af0| 68 20 74 61 62 6c 65 20 | 28 04 01 29 ca 1b 6c 61 |h table |(..)..la|
|00001b00| 62 5f 49 6e 73 74 61 6c | 6c 41 45 4f 62 6a 65 63 |b_Instal|lAEObjec|
|00001b10| 74 44 69 73 70 61 74 63 | 68 04 00 29 a2 0e 29 2e |tDispatc|h..)..).|
|00001b20| 20 57 68 65 6e 20 6f 6e | 65 20 6f 66 28 00 82 00 | When on|e of(...|
|00001b30| 48 4f 74 68 65 20 63 6f | 72 65 20 73 75 69 74 65 |HOthe co|re suite|
|00001b40| 20 65 76 65 6e 74 73 20 | 61 72 72 69 76 65 73 20 | events |arrives |
|00001b50| 61 74 20 74 68 65 20 61 | 70 70 6c 69 63 61 74 69 |at the a|pplicati|
|00001b60| 6f 6e 2c 20 74 68 65 20 | 41 70 70 6c 65 20 45 76 |on, the |Apple Ev|
|00001b70| 65 6e 74 20 4d 61 6e 61 | 67 65 72 20 63 61 6c 6c |ent Mana|ger call|
|00001b80| 73 04 01 2a 0c 17 6c 61 | 62 5f 44 69 72 65 63 74 |s..*..la|b_Direct|
|00001b90| 50 61 72 61 6d 44 69 73 | 70 61 74 63 68 04 00 29 |ParamDis|patch..)|
|00001ba0| 8e 03 2e 20 20 04 01 29 | 0a 17 6c 61 62 5f 44 69 |... ..)|..lab_Di|
|00001bb0| 72 65 63 74 50 61 72 61 | 6d 44 69 73 70 61 74 63 |rectPara|mDispatc|
|00001bc0| 68 04 00 29 8e 1e 20 65 | 78 74 72 61 63 74 73 20 |h..).. e|xtracts |
|00001bd0| 61 6e 20 6f 62 6a 65 63 | 74 20 73 70 65 63 69 66 |an objec|t specif|
|00001be0| 69 65 72 2c 28 00 9a 00 | 48 27 63 6f 6e 76 65 72 |ier,(...|H'conver|
|00001bf0| 74 73 20 69 74 20 74 6f | 20 61 20 74 6f 6b 65 6e |ts it to| a token|
|00001c00| 2c 20 61 6e 64 20 74 68 | 65 6e 20 63 61 6c 6c 73 |, and th|en calls|
|00001c10| 20 04 01 29 ac 12 6c 61 | 62 5f 53 65 6e 64 41 45 | ..)..la|b_SendAE|
|00001c20| 54 6f 4f 62 6a 65 63 74 | 04 00 29 78 1a 20 74 6f |ToObject|..)x. to|
|00001c30| 20 73 65 6e 64 20 74 68 | 69 73 20 74 6f 6b 65 6e | send th|is token|
|00001c40| 20 74 6f 20 74 68 65 28 | 00 a6 00 48 34 61 70 70 | to the(|...H4app|
|00001c50| 72 6f 70 72 69 61 74 65 | 20 6f 62 6a 65 63 74 20 |ropriate| object |
|00001c60| 66 6f 72 20 70 72 6f 63 | 65 73 73 69 6e 67 2e 20 |for proc|essing. |
|00001c70| 28 49 6e 20 6f 74 68 65 | 72 20 77 6f 72 64 73 2c |(In othe|r words,|
|00001c80| 20 04 01 29 f3 12 6c 61 | 62 5f 53 65 6e 64 41 45 | ..)..la|b_SendAE|
|00001c90| 54 6f 4f 62 6a 65 63 74 | 04 00 29 78 0b 20 69 6d |ToObject|..)x. im|
|00001ca0| 70 6c 65 6d 65 6e 74 73 | 28 00 b2 00 48 1f 4f 62 |plements|(...H.Ob|
|00001cb0| 6a 65 63 74 20 53 77 69 | 74 63 68 65 72 20 66 75 |ject Swi|tcher fu|
|00001cc0| 6e 63 74 69 6f 6e 61 6c | 69 74 79 3b 20 04 01 29 |nctional|ity; ..)|
|00001cd0| 8f 17 6c 61 62 5f 44 69 | 72 65 63 74 50 61 72 61 |..lab_Di|rectPara|
|00001ce0| 6d 44 69 73 70 61 74 63 | 68 04 00 29 8e 1d 20 6d |mDispatc|h..).. m|
|00001cf0| 65 72 65 6c 79 20 73 65 | 74 73 20 75 70 20 74 68 |erely se|ts up th|
|00001d00| 65 20 6e 65 63 65 73 73 | 61 72 79 28 00 be 00 48 |e necess|ary(...H|
|00001d10| 24 70 61 72 61 6d 65 74 | 65 72 73 20 66 6f 72 20 |$paramet|ers for |
|00001d20| 74 68 65 20 6f 62 6a 65 | 63 74 20 73 77 69 74 63 |the obje|ct switc|
|00001d30| 68 65 72 2e 29 2a 18 5a | 49 66 20 79 6f 75 20 68 |her.)*.Z|If you h|
|00001d40| 61 76 65 20 74 69 6d 65 | 2c 20 6f 72 20 77 68 65 |ave time|, or whe|
|00001d50| 6e 20 79 6f 75 20 64 65 | 63 69 64 65 20 74 6f 20 |n you de|cide to |
|00001d60| 69 6d 70 6c 65 6d 65 6e | 74 20 52 65 67 69 73 74 |implemen|t Regist|
|00001d70| 72 79 2f 44 32 20 50 61 | 72 74 20 34 20 28 43 72 |ry/D2 Pa|rt 4 (Cr|
|00001d80| 65 61 74 65 20 45 6c 65 | 6d 65 6e 74 29 2c 20 79 |eate Ele|ment), y|
|00001d90| 6f 75 2a 0c 29 6e 65 65 | 64 20 74 6f 20 77 72 69 |ou*.)nee|d to wri|
|00001da0| 74 65 20 61 6e 20 6f 70 | 74 69 6f 6e 61 6c 20 74 |te an op|tional t|
|00001db0| 68 69 72 64 20 72 6f 75 | 74 69 6e 65 2c 20 04 01 |hird rou|tine, ..|
|00001dc0| 29 b8 19 6c 61 62 5f 43 | 72 65 61 74 65 45 6c 65 |)..lab_C|reateEle|
|00001dd0| 6d 65 6e 74 44 69 73 70 | 61 74 63 68 04 00 29 9a |mentDisp|atch..).|
|00001de0| 15 2c 20 77 68 69 63 68 | 20 64 6f 65 73 20 74 68 |., which| does th|
|00001df0| 65 20 73 61 6d 65 28 00 | ee 00 48 09 74 68 69 6e |e same(.|..H.thin|
|00001e00| 67 20 61 73 20 04 01 29 | 28 17 6c 61 62 5f 44 69 |g as ..)|(.lab_Di|
|00001e10| 72 65 63 74 50 61 72 61 | 6d 44 69 73 70 61 74 63 |rectPara|mDispatc|
|00001e20| 68 04 00 29 8e 37 2c 20 | 65 78 63 65 70 74 20 74 |h..).7, |except t|
|00001e30| 68 61 74 20 69 74 20 6b | 6e 6f 77 73 20 61 62 6f |hat it k|nows abo|
|00001e40| 75 74 20 74 68 65 20 75 | 6e 69 71 75 65 20 70 61 |ut the u|nique pa|
|00001e50| 72 61 6d 65 74 65 72 73 | 20 75 73 65 64 28 00 fb |rameters| used(..|
|00001e60| 00 48 1c 62 79 20 74 68 | 65 20 43 72 65 61 74 65 |.H.by th|e Create|
|00001e70| 20 45 6c 65 6d 65 6e 74 | 20 65 76 65 6e 74 2e 0d | Element| event..|
|00001e80| 00 09 28 00 f8 00 cf 01 | 32 22 f0 00 f0 00 01 01 |..(.....|2"......|
|00001e90| a1 00 b6 00 04 00 06 00 | 19 20 02 90 00 48 02 90 |........|. ...H..|
|00001ea0| 00 d7 a1 00 b6 00 04 00 | 19 00 06 a1 00 b6 00 04 |........|........|
|00001eb0| 00 01 00 01 04 01 28 02 | 9d 00 48 01 31 04 00 0d |......(.|..H.1...|
|00001ec0| 00 0a 2b 06 03 78 20 20 | 57 65 20 68 61 76 65 20 |..+..x |We have |
|00001ed0| 62 65 65 6e 20 63 61 72 | 65 66 75 6c 20 74 6f 20 |been car|eful to |
|00001ee0| 64 65 73 69 67 6e 20 74 | 68 65 73 65 20 72 6f 75 |design t|hese rou|
|00001ef0| 74 69 6e 65 73 20 73 6f | 20 74 68 61 74 20 74 68 |tines so| that th|
|00001f00| 65 20 73 61 6d 65 20 61 | 6c 67 6f 72 69 74 68 6d |e same a|lgorithm|
|00001f10| 73 2c 20 63 61 6c 6c 69 | 6e 67 20 73 65 71 75 65 |s, calli|ng seque|
|00001f20| 6e 63 65 73 2c 20 65 74 | 63 2e 20 63 6f 75 6c 64 |nces, et|c. could|
|00001f30| 20 62 65 20 61 70 70 6c | 69 65 64 20 74 6f 28 02 | be appl|ied to(.|
|00001f40| ab 00 48 17 61 6c 6d 6f | 73 74 20 61 6e 79 20 61 |..H.almo|st any a|
|00001f50| 70 70 6c 69 63 61 74 69 | 6f 6e 2e 04 01 0d 00 09 |pplicati|on......|
|00001f60| 2a 14 01 32 04 00 0d 00 | 0a 2b 06 03 74 20 55 6e |*..2....|.+..t Un|
|00001f70| 6c 69 6b 65 20 74 68 65 | 20 72 65 73 74 20 6f 66 |like the| rest of|
|00001f80| 20 74 68 65 20 63 6f 72 | 65 20 73 75 69 74 65 20 | the cor|e suite |
|00001f90| 65 76 65 6e 74 73 2c 20 | 43 72 65 61 74 65 20 45 |events, |Create E|
|00001fa0| 6c 65 6d 65 6e 74 20 64 | 6f 65 73 20 6e 6f 74 20 |lement d|oes not |
|00001fb0| 68 61 76 65 20 61 6e 20 | 6f 62 6a 65 63 74 20 73 |have an |object s|
|00001fc0| 70 65 63 69 66 69 65 72 | 20 61 73 20 69 74 73 20 |pecifier| as its |
|00001fd0| 64 69 72 65 63 74 20 70 | 61 72 61 6d 65 74 65 72 |direct p|arameter|
|00001fe0| 2e 28 02 cd 00 48 77 54 | 68 65 72 65 66 6f 72 65 |.(...HwT|herefore|
|00001ff0| 2c 20 77 65 20 68 61 76 | 65 20 64 65 63 69 64 65 |, we hav|e decide|
|00002000| 64 20 74 6f 20 67 69 76 | 65 20 69 74 20 61 20 73 |d to giv|e it a s|
|00002010| 65 70 65 72 61 74 65 20 | 64 69 73 70 61 74 63 68 |eperate |dispatch|
|00002020| 69 6e 67 20 72 6f 75 74 | 69 6e 65 20 72 61 74 68 |ing rout|ine rath|
|00002030| 65 72 20 74 68 61 6e 20 | 63 6c 75 74 74 65 72 20 |er than |clutter |
|00002040| 75 70 20 6c 61 62 5f 44 | 69 72 65 63 74 50 61 72 |up lab_D|irectPar|
|00002050| 61 6d 65 74 65 72 44 69 | 73 70 61 74 63 68 2a 0b |ameterDi|spatch*.|
|00002060| 25 77 69 74 68 20 61 20 | 6c 61 72 67 65 20 6e 75 |%with a |large nu|
|00002070| 6d 62 65 72 20 6f 66 20 | 73 70 65 63 69 61 6c 20 |mber of |special |
|00002080| 63 61 73 65 73 2e 0d 00 | 0c 2a 16 14 44 65 76 65 |cases...|.*..Deve|
|00002090| 6c 6f 70 65 72 20 55 6e | 69 76 65 72 73 69 74 79 |loper Un|iversity|
|000020a0| 29 e0 02 2d 20 29 07 01 | 32 29 06 02 20 2d 29 95 |)..- )..|2).. -).|
|000020b0| 18 52 65 67 69 73 74 72 | 79 20 2f 20 44 31 20 20 |.Registr|y / D1 |
|000020c0| 4c 61 62 20 4e 6f 74 65 | 73 ff 00 0c 00 00 00 00 |Lab Note|s.......|
|000020d0| 02 d7 02 23 11 01 0c 00 | 1e 00 1f 01 00 0a 00 00 |...#....|........|
|000020e0| 00 00 03 15 02 5f 2c 00 | 08 00 14 05 54 69 6d 65 |....._,.|....Time|
|000020f0| 73 03 00 14 04 01 0d 00 | 18 2e 00 04 00 00 00 00 |s.......|........|
|00002100| 2b 48 36 12 53 74 61 72 | 74 20 6f 66 20 4c 61 62 |+H6.Star|t of Lab|
|00002110| 20 53 74 65 70 73 0d 00 | 0e 2a 24 02 31 2e 29 24 | Steps..|.*$.1.)$|
|00002120| 2e 49 6d 70 6c 65 6d 65 | 6e 74 20 74 68 65 20 6c |.Impleme|nt the l|
|00002130| 61 62 5f 44 69 72 65 63 | 74 50 61 72 61 6d 44 69 |ab_Direc|tParamDi|
|00002140| 73 70 61 74 63 68 20 72 | 6f 75 74 69 6e 65 2e 2c |spatch r|outine.,|
|00002150| 00 0a 00 16 07 43 6f 75 | 72 69 65 72 03 00 16 0d |.....Cou|rier....|
|00002160| 00 0c 2a 1f 04 48 6f 6f | 6b 04 00 29 20 01 3a 0d |..*..Hoo|k..) .:.|
|00002170| 00 0a 2b 16 1e 26 70 61 | 73 63 61 6c 20 4f 53 45 |..+..&pa|scal OSE|
|00002180| 72 72 20 6c 61 62 5f 44 | 69 72 65 63 74 50 61 72 |rr lab_D|irectPar|
|00002190| 61 6d 44 69 73 70 61 74 | 63 68 20 28 04 01 2b 36 |amDispat|ch (..+6|
|000021a0| 12 0a 41 70 70 6c 65 45 | 76 65 6e 74 04 00 29 46 |..AppleE|vent..)F|
|000021b0| 0a 20 2a 6d 65 73 73 61 | 67 65 2c 04 01 28 00 bb |. *messa|ge,..(..|
|000021c0| 00 d8 0a 41 70 70 6c 65 | 45 76 65 6e 74 04 00 29 |...Apple|Event..)|
|000021d0| 46 08 20 2a 72 65 70 6c | 79 2c 28 00 cd 00 d8 0d |F. *repl|y,(.....|
|000021e0| 6c 6f 6e 67 20 72 65 66 | 63 6f 6e 29 3b 03 00 14 |long ref|con);...|
|000021f0| 0d 00 0c 28 00 fc 00 6c | 58 4f 6e 63 65 20 69 6e |...(...l|XOnce in|
|00002200| 73 74 61 6c 6c 65 64 2c | 20 74 68 69 73 20 68 6f |stalled,| this ho|
|00002210| 6f 6b 20 72 6f 75 74 69 | 6e 65 20 69 73 20 63 61 |ok routi|ne is ca|
|00002220| 6c 6c 65 64 20 62 79 20 | 74 68 65 20 41 70 70 6c |lled by |the Appl|
|00002230| 65 20 45 76 65 6e 74 20 | 4d 61 6e 61 67 65 72 20 |e Event |Manager |
|00002240| 74 6f 20 68 61 6e 64 6c | 65 20 61 6c 6c 20 74 68 |to handl|e all th|
|00002250| 65 2a 0c 56 43 6f 72 65 | 20 53 75 69 74 65 20 65 |e*.VCore| Suite e|
|00002260| 76 65 6e 74 73 2e 20 54 | 68 65 20 73 68 65 6c 6c |vents. T|he shell|
|00002270| 20 64 6f 65 73 20 6e 6f | 20 70 72 6f 63 65 73 73 | does no| process|
|00002280| 69 6e 67 20 6f 66 20 74 | 68 65 20 65 76 65 6e 74 |ing of t|he event|
|00002290| 20 62 65 66 6f 72 65 20 | 70 61 73 73 69 6e 67 20 | before |passing |
|000022a0| 69 74 20 74 6f 20 74 68 | 69 73 2a 0c 3a 68 6f 6f |it to th|is*.:hoo|
|000022b0| 6b 2e 20 54 68 65 72 65 | 66 6f 72 65 2c 20 74 68 |k. There|fore, th|
|000022c0| 65 20 68 6f 6f 6b 20 69 | 73 2c 20 66 6f 72 20 61 |e hook i|s, for a|
|000022d0| 6c 6c 20 70 72 61 63 74 | 69 63 61 6c 20 70 75 72 |ll pract|ical pur|
|000022e0| 70 6f 73 65 73 2c 20 04 | 04 28 01 14 01 76 03 74 |poses, .|.(...v.t|
|000022f0| 68 65 04 00 29 0e 19 20 | 65 6e 74 72 79 20 70 6f |he..).. |entry po|
|00002300| 69 6e 74 20 66 6f 72 20 | 61 6c 6c 20 43 6f 72 65 |int for |all Core|
|00002310| 28 01 20 00 6c 4c 53 75 | 69 74 65 20 65 76 65 6e |(. .lLSu|ite even|
|00002320| 74 73 20 65 78 63 65 70 | 74 20 43 72 65 61 74 65 |ts excep|t Create|
|00002330| 20 45 6c 65 6d 65 6e 74 | 20 28 77 68 69 63 68 20 | Element| (which |
|00002340| 68 61 73 20 61 6e 20 75 | 6e 75 73 75 61 6c 20 73 |has an u|nusual s|
|00002350| 65 74 20 6f 66 20 70 61 | 72 61 6d 65 74 65 72 73 |et of pa|rameters|
|00002360| 29 2e 2a 18 52 55 6e 74 | 69 6c 20 79 6f 75 20 69 |).*.RUnt|il you i|
|00002370| 6e 73 74 61 6c 6c 20 74 | 68 69 73 20 72 6f 75 74 |nstall t|his rout|
|00002380| 69 6e 65 2c 20 74 68 65 | 20 6c 61 62 20 75 73 65 |ine, the| lab use|
|00002390| 73 20 61 20 73 69 6d 70 | 6c 65 20 64 69 73 70 61 |s a simp|le dispa|
|000023a0| 74 63 68 20 72 6f 75 74 | 69 6e 65 20 6f 66 20 69 |tch rout|ine of i|
|000023b0| 74 73 20 6f 77 6e 2e 2a | 0c 52 48 6f 77 65 76 65 |ts own.*|.RHoweve|
|000023c0| 72 2c 20 74 68 65 20 6c | 61 62 d5 73 20 64 69 73 |r, the l|ab.s dis|
|000023d0| 70 61 74 63 68 65 72 20 | 64 6f 65 73 20 6e 6f 74 |patcher |does not|
|000023e0| 20 6b 6e 6f 77 20 61 62 | 6f 75 74 20 74 68 65 20 | know ab|out the |
|000023f0| 63 41 70 70 6f 69 6e 74 | 6d 65 6e 74 20 63 6c 61 |cAppoint|ment cla|
|00002400| 73 73 2c 20 61 6e 64 20 | 74 68 69 73 2a 0c 2d 69 |ss, and |this*.-i|
|00002410| 73 20 77 68 79 20 79 6f | 75 20 68 61 76 65 20 74 |s why yo|u have t|
|00002420| 6f 20 77 72 69 74 65 20 | 79 6f 75 72 20 6f 77 6e |o write |your own|
|00002430| 20 64 69 73 70 61 74 63 | 68 65 72 2e 2a 18 2e 54 | dispatc|her.*..T|
|00002440| 68 65 20 68 6f 6f 6b d5 | 73 20 75 6c 74 69 6d 61 |he hook.|s ultima|
|00002450| 74 65 20 72 65 73 70 6f | 6e 73 69 62 69 6c 69 74 |te respo|nsibilit|
|00002460| 79 20 69 73 20 74 6f 20 | 63 61 6c 6c 20 04 01 29 |y is to |call ..)|
|00002470| ce 12 6c 61 62 5f 53 65 | 6e 64 41 45 54 6f 4f 62 |..lab_Se|ndAEToOb|
|00002480| 6a 65 63 74 04 00 29 78 | 0e 2e 20 41 73 20 6d 65 |ject..)x|.. As me|
|00002490| 6e 74 69 6f 6e 65 64 28 | 01 74 00 6c 1d 69 6e 20 |ntioned(|.t.l.in |
|000024a0| 74 68 65 20 6c 61 62 d5 | 73 20 73 79 6e 6f 70 73 |the lab.|s synops|
|000024b0| 69 73 20 61 62 6f 76 65 | 2c 20 04 01 29 87 12 6c |is above|, ..)..l|
|000024c0| 61 62 5f 53 65 6e 64 41 | 45 54 6f 4f 62 6a 65 63 |ab_SendA|EToObjec|
|000024d0| 74 04 00 29 78 1e d5 73 | 20 6a 6f 62 20 69 73 20 |t..)x..s| job is |
|000024e0| 74 6f 20 70 61 73 73 20 | 74 68 65 20 69 6e 63 6f |to pass |the inco|
|000024f0| 6d 69 6e 67 28 01 80 00 | 6c 2d 41 45 20 74 6f 20 |ming(...|l-AE to |
|00002500| 74 68 65 20 61 70 70 72 | 6f 70 72 69 61 74 65 20 |the appr|opriate |
|00002510| 6f 62 6a 65 63 74 20 68 | 61 6e 64 6c 69 6e 67 20 |object h|andling |
|00002520| 6c 6f 67 69 63 2e 20 04 | 01 29 d0 12 6c 61 62 5f |logic. .|.)..lab_|
|00002530| 53 65 6e 64 41 45 54 6f | 4f 62 6a 65 63 74 04 00 |SendAETo|Object..|
|00002540| 29 78 0d 20 68 61 73 20 | 61 20 66 61 69 72 6c 79 |)x. has |a fairly|
|00002550| 28 01 8c 00 6c 28 69 6e | 76 6f 6c 76 65 64 20 63 |(...l(in|volved c|
|00002560| 61 6c 6c 69 6e 67 20 73 | 65 71 75 65 6e 63 65 20 |alling s|equence |
|00002570| 28 67 69 76 65 6e 20 62 | 65 6c 6f 77 29 2e 03 00 |(given b|elow)...|
|00002580| 16 0d 00 09 2a 17 1a 4f | 53 45 72 72 20 6c 61 62 |....*..O|SErr lab|
|00002590| 5f 53 65 6e 64 41 45 54 | 6f 4f 62 6a 65 63 74 20 |_SendAET|oObject |
|000025a0| 28 2b 24 0a 05 63 6f 6e | 73 74 29 67 0a 41 70 70 |(+$..con|st)g.App|
|000025b0| 6c 65 45 76 65 6e 74 29 | 44 0a 2a 6d 65 73 73 61 |leEvent)|D.*messa|
|000025c0| 67 65 2c 20 29 51 14 2f | 2f 31 2e 20 74 68 65 20 |ge, )Q./|/1. the |
|000025d0| 69 6e 63 6f 6d 69 6e 67 | 20 41 45 28 01 b7 00 f7 |incoming| AE(....|
|000025e0| 0a 41 70 70 6c 65 45 76 | 65 6e 74 29 44 08 2a 72 |.AppleEv|ent)D.*r|
|000025f0| 65 70 6c 79 2c 20 29 51 | 22 2f 2f 32 2e 20 41 45 |eply, )Q|"//2. AE|
|00002600| 20 72 65 70 6c 79 20 28 | 69 66 20 6e 6f 74 20 61 | reply (|if not a|
|00002610| 20 6e 75 6c 6c 20 64 65 | 73 63 29 28 01 c1 00 f7 | null de|sc)(....|
|00002620| 04 6c 6f 6e 67 29 44 08 | 20 72 65 66 43 6f 6e 2c |.long)D.| refCon,|
|00002630| 29 51 23 2f 2f 33 2e 20 | 45 76 65 6e 74 20 68 61 |)Q#//3. |Event ha|
|00002640| 6e 64 6c 65 72 20 72 65 | 66 63 6f 6e 20 28 69 67 |ndler re|fcon (ig|
|00002650| 6e 6f 72 65 64 29 28 01 | cb 00 f7 0c 41 45 45 76 |nored)(.|....AEEv|
|00002660| 65 6e 74 43 6c 61 73 73 | 29 44 0a 20 63 6c 61 73 |entClass|)D. clas|
|00002670| 73 49 44 2c 20 29 51 24 | 2f 2f 34 2e 20 41 45 20 |sID, )Q$|//4. AE |
|00002680| 63 6c 61 73 73 49 44 20 | 28 61 6c 77 61 79 73 20 |classID |(always |
|00002690| d4 61 65 76 74 d5 20 68 | 65 72 65 29 28 01 d5 00 |.aevt. h|ere)(...|
|000026a0| f7 09 41 45 45 76 65 6e | 74 49 44 29 44 09 20 65 |..AEEven|tID)D. e|
|000026b0| 76 65 6e 74 49 44 2c 29 | 51 26 2f 2f 35 2e 20 41 |ventID,)|Q&//5. A|
|000026c0| 45 20 65 76 65 6e 74 49 | 44 20 28 61 20 43 6f 72 |E eventI|D (a Cor|
|000026d0| 65 20 53 75 69 74 65 20 | 49 44 20 68 65 72 65 29 |e Suite |ID here)|
|000026e0| 28 01 df 00 f7 08 44 65 | 73 63 54 79 70 65 29 44 |(.....De|scType)D|
|000026f0| 31 20 64 69 73 70 61 74 | 63 68 43 6c 61 73 73 2c |1 dispat|chClass,|
|00002700| 20 2f 2f 36 2e 20 63 6c | 61 73 73 20 49 44 20 6f | //6. cl|ass ID o|
|00002710| 66 20 4f 62 6a 65 63 74 | 20 74 6f 20 68 61 6e 64 |f Object| to hand|
|00002720| 6c 65 28 01 e9 00 90 05 | 65 76 65 6e 74 2a 0a 05 |le(.....|event*..|
|00002730| 63 6f 6e 73 74 29 67 06 | 41 45 44 65 73 63 29 44 |const)g.|AEDesc)D|
|00002740| 08 2a 6f 73 70 65 63 2c | 20 29 51 19 2f 2f 37 2e |.*ospec,| )Q.//7.|
|00002750| 20 64 69 72 65 63 74 20 | 70 61 72 61 6d 20 66 72 | direct |param fr|
|00002760| 6f 6d 20 41 45 28 01 fd | 00 90 05 63 6f 6e 73 74 |om AE(..|...const|
|00002770| 29 67 06 41 45 44 65 73 | 63 29 44 08 2a 74 6f 6b |)g.AEDes|c)D.*tok|
|00002780| 65 6e 29 3b 29 51 22 2f | 2f 38 2e 20 74 6f 6b 65 |en);)Q"/|/8. toke|
|00002790| 6e 20 6f 62 74 61 69 6e | 65 64 20 66 72 6f 6d 20 |n obtain|ed from |
|000027a0| 41 45 52 65 73 6f 6c 76 | 65 03 00 14 0d 00 0c 28 |AEResolv|e......(|
|000027b0| 02 14 00 6c 53 45 61 63 | 68 20 6f 66 20 74 68 65 |...lSEac|h of the|
|000027c0| 20 43 6f 72 65 20 65 76 | 65 6e 74 73 20 28 65 78 | Core ev|ents (ex|
|000027d0| 63 65 70 74 20 43 72 65 | 61 74 65 20 45 6c 65 6d |cept Cre|ate Elem|
|000027e0| 65 6e 74 29 20 63 6f 6e | 74 61 69 6e 73 20 61 6e |ent) con|tains an|
|000027f0| 20 6f 62 6a 65 63 74 20 | 73 70 65 63 69 66 69 65 | object |specifie|
|00002800| 72 20 61 73 20 69 74 73 | 2a 0c 53 64 69 72 65 63 |r as its|*.Sdirec|
|00002810| 74 20 70 61 72 61 6d 65 | 74 65 72 20 28 6b 65 79 |t parame|ter (key|
|00002820| 44 69 72 65 63 74 4f 62 | 6a 65 63 74 29 2e 20 54 |DirectOb|ject). T|
|00002830| 68 69 73 20 6f 73 70 65 | 63 20 6e 65 65 64 73 20 |his ospe|c needs |
|00002840| 74 6f 20 62 65 20 65 78 | 74 72 61 63 74 65 64 2c |to be ex|tracted,|
|00002850| 20 72 65 73 6f 6c 76 65 | 64 2c 20 61 6e 64 2a 0c | resolve|d, and*.|
|00002860| 0a 70 61 73 73 65 64 20 | 74 6f 20 04 01 29 2f 12 |.passed |to ..)/.|
|00002870| 6c 61 62 5f 53 65 6e 64 | 41 45 54 6f 4f 62 6a 65 |lab_Send|AEToObje|
|00002880| 63 74 04 00 29 78 2c 2e | 20 50 61 72 61 6d 65 74 |ct..)x,.| Paramet|
|00002890| 65 72 73 20 6f 6e 65 2c | 20 74 77 6f 2c 20 74 68 |ers one,| two, th|
|000028a0| 72 65 65 2c 20 61 6e 64 | 20 73 65 76 65 6e 20 63 |ree, and| seven c|
|000028b0| 6f 6d 65 28 02 38 00 6c | 55 64 69 72 65 63 74 6c |ome(.8.l|Udirectl|
|000028c0| 79 20 66 72 6f 6d 20 74 | 68 65 20 41 70 70 6c 65 |y from t|he Apple|
|000028d0| 20 45 76 65 6e 74 20 4d | 61 6e 61 67 65 72 2c 20 | Event M|anager, |
|000028e0| 70 61 72 61 6d 65 74 65 | 72 73 20 34 20 61 6e 64 |paramete|rs 4 and|
|000028f0| 20 35 20 61 72 65 20 61 | 74 74 72 69 62 75 74 65 | 5 are a|ttribute|
|00002900| 73 20 6f 66 20 74 68 65 | 20 41 70 70 6c 65 2a 0c |s of the| Apple*.|
|00002910| 3d 65 76 65 6e 74 2c 20 | 61 6e 64 20 70 61 72 61 |=event, |and para|
|00002920| 6d 65 74 65 72 20 65 69 | 67 68 74 20 63 6f 6d 65 |meter ei|ght come|
|00002930| 73 20 66 72 6f 6d 20 41 | 45 52 65 73 6f 6c 76 65 |s from A|EResolve|
|00002940| 20 28 61 73 20 63 61 6c | 6c 65 64 20 62 79 04 01 | (as cal|led by..|
|00002950| 2a 0c 17 6c 61 62 5f 44 | 69 72 65 63 74 50 61 72 |*..lab_D|irectPar|
|00002960| 61 6d 44 69 73 70 61 74 | 63 68 04 00 29 8e 02 2e |amDispat|ch..)...|
|00002970| 29 28 02 68 00 6c 4c 4e | 6f 74 65 20 74 68 61 74 |)(.h.lLN|ote that|
|00002980| 20 77 65 20 68 61 76 65 | 6e d5 74 20 6d 65 6e 74 | we have|n.t ment|
|00002990| 69 6f 6e 65 64 20 70 61 | 72 61 6d 65 74 65 72 20 |ioned pa|rameter |
|000029a0| 73 69 78 20 d1 20 74 68 | 65 20 d2 64 69 73 70 61 |six . th|e .dispa|
|000029b0| 74 63 68 20 63 6c 61 73 | 73 d3 d1 ca 61 73 20 74 |tch clas|s...as t|
|000029c0| 68 69 73 2a 0c 57 72 65 | 71 75 69 72 65 73 20 61 |his*.Wre|quires a|
|000029d0| 20 62 69 74 20 6d 6f 72 | 65 20 65 78 70 6c 61 6e | bit mor|e explan|
|000029e0| 61 74 69 6f 6e 2e 20 54 | 68 69 73 20 63 6c 61 73 |ation. T|his clas|
|000029f0| 73 20 73 68 6f 75 6c 64 | 20 62 65 20 74 68 65 20 |s should| be the |
|00002a00| 6f 62 6a 65 63 74 20 74 | 79 70 65 20 72 65 66 65 |object t|ype refe|
|00002a10| 72 65 6e 63 65 64 20 62 | 79 20 74 68 65 2a 0c 52 |renced b|y the*.R|
|00002a20| 74 6f 6b 65 6e 2c 20 62 | 75 74 20 74 68 65 72 65 |token, b|ut there|
|00002a30| d5 73 20 61 20 70 72 6f | 62 6c 65 6d 2e 20 49 66 |.s a pro|blem. If|
|00002a40| 20 74 68 65 20 74 6f 6b | 65 6e 20 72 65 70 72 65 | the tok|en repre|
|00002a50| 73 65 6e 74 73 20 61 6e | 20 6f 62 6a 65 63 74 20 |sents an| object |
|00002a60| 28 63 41 70 70 6c 69 63 | 61 74 69 6f 6e 2c 20 66 |(cApplic|ation, f|
|00002a70| 6f 72 2a 0c 4d 65 78 61 | 6d 70 6c 65 20 29 2c 20 |or*.Mexa|mple ), |
|00002a80| 79 6f 75 20 63 61 6e 20 | 67 65 74 20 74 68 65 20 |you can |get the |
|00002a90| 6f 62 6a 65 63 74 20 74 | 79 70 65 20 66 72 6f 6d |object t|ype from|
|00002aa0| 20 74 68 65 20 74 6f 6b | 65 6e d5 73 20 64 65 73 | the tok|en.s des|
|00002ab0| 63 72 69 70 74 6f 72 54 | 79 70 65 20 66 69 65 6c |criptorT|ype fiel|
|00002ac0| 64 2e 2a 0c 55 48 6f 77 | 65 76 65 72 2c 20 69 66 |d.*.UHow|ever, if|
|00002ad0| 20 74 68 65 20 74 6f 6b | 65 6e 20 72 65 70 72 65 | the tok|en repre|
|00002ae0| 73 65 6e 74 73 20 61 20 | 70 72 6f 70 65 72 74 79 |sents a |property|
|00002af0| 2c 20 77 65 20 75 73 75 | 61 6c 6c 79 20 73 65 74 |, we usu|ally set|
|00002b00| 20 74 68 65 20 64 65 73 | 63 72 69 70 74 6f 72 54 | the des|criptorT|
|00002b10| 79 70 65 20 20 66 69 65 | 6c 64 2a 0c 58 74 6f 20 |ype fie|ld*.Xto |
|00002b20| d4 70 72 6f 70 d5 2e 20 | 54 68 65 72 65 66 6f 72 |.prop.. |Therefor|
|00002b30| 65 2c 20 65 61 63 68 20 | 74 6f 6b 65 6e 20 63 6f |e, each |token co|
|00002b40| 6e 74 61 69 6e 73 20 74 | 68 65 20 34 2d 62 79 74 |ntains t|he 4-byt|
|00002b50| 65 20 63 6f 64 65 20 66 | 6f 72 20 69 74 73 20 6f |e code f|or its o|
|00002b60| 62 6a 65 63 74 20 74 79 | 70 65 20 77 68 65 74 68 |bject ty|pe wheth|
|00002b70| 65 72 20 69 74 2a 0c 53 | 69 73 20 61 6e 20 6f 62 |er it*.S|is an ob|
|00002b80| 6a 65 63 74 20 74 6f 6b | 65 6e 20 6f 72 20 61 20 |ject tok|en or a |
|00002b90| 70 72 6f 70 65 72 74 79 | 20 74 6f 6b 65 6e 2e 20 |property| token. |
|00002ba0| 54 68 69 73 20 63 6f 64 | 65 20 6d 61 79 20 62 65 |This cod|e may be|
|00002bb0| 20 61 63 63 65 73 73 65 | 64 20 75 73 69 6e 67 20 | accesse|d using |
|00002bc0| 74 68 65 20 74 6f 6b 65 | 6e d5 73 2a 0c 2c 64 69 |the toke|n.s*.,di|
|00002bd0| 73 70 61 74 63 68 43 6c | 61 73 73 20 66 69 65 6c |spatchCl|ass fiel|
|00002be0| 64 20 64 69 72 65 63 74 | 6c 79 20 6f 72 20 74 68 |d direct|ly or th|
|00002bf0| 72 6f 75 67 68 20 74 68 | 65 20 04 01 29 c8 12 74 |rough th|e ..)..t|
|00002c00| 6f 6b 65 6e 44 69 73 70 | 61 74 63 68 43 6c 61 73 |okenDisp|atchClas|
|00002c10| 73 04 00 29 6f 07 20 6d | 61 63 72 6f 2e 28 02 ee |s..)o. m|acro.(..|
|00002c20| 00 48 14 44 65 76 65 6c | 6f 70 65 72 20 55 6e 69 |.H.Devel|oper Uni|
|00002c30| 76 65 72 73 69 74 79 29 | e0 02 2d 20 29 07 01 33 |versity)|..- )..3|
|00002c40| 29 06 02 20 2d 29 95 18 | 52 65 67 69 73 74 72 79 |).. -)..|Registry|
|00002c50| 20 2f 20 44 31 20 20 4c | 61 62 20 4e 6f 74 65 73 | / D1 L|ab Notes|
|00002c60| ff 00 0c 00 00 00 00 02 | d7 02 23 11 01 0c 00 1e |........|..#.....|
|00002c70| 00 1f 01 00 0a 00 00 00 | 00 03 15 02 5f 2c 00 08 |........|...._,..|
|00002c80| 00 14 05 54 69 6d 65 73 | 03 00 14 04 05 0d 00 0c |...Times|........|
|00002c90| 2e 00 04 00 00 00 00 2b | 6c 2d 17 49 6d 70 6c 65 |.......+|l-.Imple|
|00002ca0| 6d 65 6e 74 61 74 69 6f | 6e 20 d2 52 65 63 69 70 |mentatio|n .Recip|
|00002cb0| 65 d3 04 00 2b 24 12 02 | 31 2e 29 12 4b 45 78 74 |e...+$..|1.).KExt|
|00002cc0| 72 61 63 74 20 74 68 65 | 20 41 70 70 6c 65 20 65 |ract the| Apple e|
|00002cd0| 76 65 6e 74 d5 73 20 d2 | 65 76 65 6e 74 20 63 6c |vent.s .|event cl|
|00002ce0| 61 73 73 d3 20 61 6e 64 | 20 d2 65 76 65 6e 74 20 |ass. and| .event |
|00002cf0| 49 44 d3 20 70 61 72 61 | 6d 65 74 65 72 73 20 75 |ID. para|meters u|
|00002d00| 73 69 6e 67 20 74 68 65 | 04 01 2a 0c 11 41 45 47 |sing the|..*..AEG|
|00002d10| 65 74 41 74 74 72 69 62 | 75 74 65 50 74 72 04 00 |etAttrib|utePtr..|
|00002d20| 29 68 36 20 72 6f 75 74 | 69 6e 65 20 61 6e 64 20 |)h6 rout|ine and |
|00002d30| 61 20 63 6f 75 70 6c 65 | 20 6f 66 20 6c 6f 63 61 |a couple| of loca|
|00002d40| 6c 20 76 61 72 69 61 62 | 6c 65 73 20 66 6f 72 20 |l variab|les for |
|00002d50| 74 68 65 20 65 76 65 6e | 74 28 00 57 00 a2 0d 63 |the even|t(.W...c|
|00002d60| 6c 61 73 73 20 61 6e 64 | 20 49 44 2e 28 00 69 00 |lass and| ID.(.i.|
|00002d70| 90 02 32 2e 29 12 3b 45 | 78 74 72 61 63 74 20 74 |..2.).;E|xtract t|
|00002d80| 68 65 20 64 69 72 65 63 | 74 20 70 61 72 61 6d 65 |he direc|t parame|
|00002d90| 74 65 72 2c 20 77 68 69 | 63 68 20 69 73 20 61 6e |ter, whi|ch is an|
|00002da0| 20 6f 62 6a 65 63 74 20 | 73 70 65 63 69 66 69 65 | object |specifie|
|00002db0| 72 2e 28 00 7b 00 90 02 | 33 2e 29 12 34 52 65 73 |r.(.{...|3.).4Res|
|00002dc0| 6f 6c 76 65 20 74 68 65 | 20 64 69 72 65 63 74 20 |olve the| direct |
|00002dd0| 70 61 72 61 6d 65 74 65 | 72 20 75 73 69 6e 67 20 |paramete|r using |
|00002de0| 41 45 52 65 73 6f 6c 76 | 65 2e 20 28 50 61 73 73 |AEResolv|e. (Pass|
|00002df0| 20 04 01 29 fe 0d 6b 41 | 45 49 44 6f 4d 69 6e 69 | ..)..kA|EIDoMini|
|00002e00| 6d 75 6d 04 00 28 00 87 | 00 a2 21 66 6f 72 20 74 |mum..(..|..!for t|
|00002e10| 68 65 20 63 61 6c 6c 62 | 61 63 6b 46 6c 61 67 73 |he callb|ackFlags|
|00002e20| 20 70 61 72 61 6d 65 74 | 65 72 2e 29 2a 12 4b 4e | paramet|er.)*.KN|
|00002e30| 6f 74 65 20 74 68 61 74 | 20 41 45 52 65 73 6f 6c |ote that| AEResol|
|00002e40| 76 65 20 72 65 74 75 72 | 6e 73 20 61 6e 20 65 72 |ve retur|ns an er|
|00002e50| 72 6f 72 20 69 66 20 61 | 73 6b 65 64 20 74 6f 20 |ror if a|sked to |
|00002e60| 72 65 73 6f 6c 76 65 20 | 61 20 6e 75 6c 6c 20 64 |resolve |a null d|
|00002e70| 65 73 63 72 69 70 74 6f | 72 2e 2a 0c 48 53 6f 2c |escripto|r.*.HSo,|
|00002e80| 20 64 6f 20 6e 6f 74 20 | 63 61 6c 6c 20 41 45 52 | do not |call AER|
|00002e90| 65 73 6f 6c 76 65 20 77 | 69 74 68 20 61 20 6e 75 |esolve w|ith a nu|
|00002ea0| 6c 6c 20 6f 73 70 65 63 | 2c 20 62 75 74 20 67 65 |ll ospec|, but ge|
|00002eb0| 6e 65 72 61 74 65 20 79 | 6f 75 72 20 6f 77 6e 20 |nerate y|our own |
|00002ec0| 74 6f 6b 65 6e 2a 0c 4d | 62 79 20 73 65 74 74 69 |token*.M|by setti|
|00002ed0| 6e 67 20 74 68 65 20 74 | 6f 6b 65 6e 20 74 6f 20 |ng the t|oken to |
|00002ee0| 61 20 6e 75 6c 6c 20 64 | 65 73 63 72 69 70 74 6f |a null d|escripto|
|00002ef0| 72 20 61 6e 64 20 70 61 | 73 73 69 6e 67 20 74 68 |r and pa|ssing th|
|00002f00| 61 74 20 61 73 20 74 68 | 65 20 74 6f 6b 65 6e 2e |at as th|e token.|
|00002f10| 20 28 54 68 65 2a 0c 2e | 64 69 73 70 61 74 63 68 | (The*..|dispatch|
|00002f20| 20 63 6c 61 73 73 20 73 | 68 6f 75 6c 64 20 62 65 | class s|hould be|
|00002f30| 20 d4 6e 75 6c 6c d5 20 | 69 6e 20 74 68 61 74 20 | .null. |in that |
|00002f40| 63 61 73 65 2e 29 28 00 | cf 00 90 02 34 2e 29 12 |case.)(.|....4.).|
|00002f50| 05 43 61 6c 6c 20 04 01 | 29 16 12 6c 61 62 5f 53 |.Call ..|)..lab_S|
|00002f60| 65 6e 64 41 45 54 6f 4f | 62 6a 65 63 74 04 00 29 |endAEToO|bject..)|
|00002f70| 78 14 20 61 73 20 64 65 | 73 63 72 69 62 65 64 20 |x. as de|scribed |
|00002f80| 61 62 6f 76 65 2e 04 05 | 28 00 e7 00 6c 07 54 65 |above...|(...l.Te|
|00002f90| 73 74 69 6e 67 04 00 29 | 2a 02 3a 20 29 0c 3b 59 |sting..)|*.: ).;Y|
|00002fa0| 6f 75 20 6e 65 65 64 20 | 74 6f 20 63 6f 6d 70 6c |ou need |to compl|
|00002fb0| 65 74 65 20 73 74 65 70 | 73 20 32 20 61 6e 64 20 |ete step|s 2 and |
|00002fc0| 33 20 62 65 66 6f 72 65 | 20 74 65 73 74 69 6e 67 |3 before| testing|
|00002fd0| 20 74 68 69 73 20 6c 61 | 62 2e 04 05 28 00 ff 00 | this la|b...(...|
|00002fe0| 6c 18 52 65 71 75 69 72 | 65 64 20 53 68 65 6c 6c |l.Requir|ed Shell|
|00002ff0| 20 55 74 69 6c 69 74 69 | 65 73 04 00 29 86 01 3a | Utiliti|es..)..:|
|00003000| 2c 00 0a 00 16 07 43 6f | 75 72 69 65 72 03 00 16 |,.....Co|urier...|
|00003010| 0d 00 09 28 01 16 00 7e | 04 6e 6f 6e 65 03 00 14 |...(...~|.none...|
|00003020| 04 05 0d 00 0c 28 01 2d | 00 6c 14 52 65 71 75 69 |.....(.-|.l.Requi|
|00003030| 72 65 64 20 4f 53 20 52 | 6f 75 74 69 6e 65 73 04 |red OS R|outines.|
|00003040| 00 29 7e 01 3a 03 00 16 | 0d 00 09 28 01 3e 00 7e |.)~.:...|...(.>.~|
|00003050| 4a 70 61 73 63 61 6c 20 | 4f 53 45 72 72 20 41 45 |Jpascal |OSErr AE|
|00003060| 47 65 74 41 74 74 72 69 | 62 75 74 65 50 74 72 20 |GetAttri|butePtr |
|00003070| 28 63 6f 6e 73 74 20 41 | 70 70 6c 65 45 76 65 6e |(const A|ppleEven|
|00003080| 74 20 2a 74 68 65 41 70 | 70 6c 65 45 76 65 6e 74 |t *theAp|pleEvent|
|00003090| 2c 20 41 45 4b 65 79 57 | 6f 72 64 2b 5a 0a 3b 74 |, AEKeyW|ord+Z.;t|
|000030a0| 68 65 41 45 4b 65 79 77 | 6f 72 64 2c 20 44 65 73 |heAEKeyw|ord, Des|
|000030b0| 63 54 79 70 65 20 64 65 | 73 69 72 65 64 54 79 70 |cType de|siredTyp|
|000030c0| 65 2c 20 44 65 73 63 54 | 79 70 65 20 2a 74 79 70 |e, DescT|ype *typ|
|000030d0| 65 43 6f 64 65 2c 20 50 | 74 72 2a 0a 2d 64 61 74 |eCode, P|tr*.-dat|
|000030e0| 61 50 74 72 2c 20 53 69 | 7a 65 20 6d 61 78 69 6d |aPtr, Si|ze maxim|
|000030f0| 75 6d 53 69 7a 65 2c 20 | 53 69 7a 65 20 2a 61 63 |umSize, |Size *ac|
|00003100| 74 75 61 6c 53 69 7a 65 | 29 3b 28 01 62 00 7e 54 |tualSize|);(.b.~T|
|00003110| 70 61 73 63 61 6c 20 4f | 53 45 72 72 20 41 45 47 |pascal O|SErr AEG|
|00003120| 65 74 50 61 72 61 6d 44 | 65 73 63 28 63 6f 6e 73 |etParamD|esc(cons|
|00003130| 74 20 41 70 70 6c 65 45 | 76 65 6e 74 20 2a 74 68 |t AppleE|vent *th|
|00003140| 65 41 70 70 6c 65 45 76 | 65 6e 74 2c 20 41 45 4b |eAppleEv|ent, AEK|
|00003150| 65 79 57 6f 72 64 20 74 | 68 65 41 45 4b 65 79 77 |eyWord t|heAEKeyw|
|00003160| 6f 72 64 2c 2b 5a 0a 26 | 44 65 73 63 54 79 70 65 |ord,+Z.&|DescType|
|00003170| ca 64 65 73 69 72 65 64 | 54 79 70 65 2c 20 41 45 |.desired|Type, AE|
|00003180| 44 65 73 63 20 2a 72 65 | 73 75 6c 74 29 3b 28 01 |Desc *re|sult);(.|
|00003190| 7c 00 7e 4b 70 61 73 63 | 61 6c 20 4f 53 45 72 72 ||.~Kpasc|al OSErr|
|000031a0| 20 41 45 52 65 73 6f 6c | 76 65 20 28 63 6f 6e 73 | AEResol|ve (cons|
|000031b0| 74 20 41 45 44 65 73 63 | 20 2a 6f 62 6a 65 63 74 |t AEDesc| *object|
|000031c0| 53 70 65 63 69 66 69 65 | 72 2c 20 73 68 6f 72 74 |Specifie|r, short|
|000031d0| 20 63 61 6c 6c 62 61 63 | 6b 46 6c 61 67 73 2c 2b | callbac|kFlags,+|
|000031e0| 5a 0a 12 41 45 44 65 73 | 63 ca 2a 74 68 65 54 6f |Z..AEDes|c.*theTo|
|000031f0| 6b 65 6e 29 3b 03 00 14 | 04 01 0d 00 0e 28 01 b2 |ken);...|.....(..|
|00003200| 00 48 02 32 2e 29 24 2c | 49 6e 73 74 61 6c 6c 20 |.H.2.)$,|Install |
|00003210| 74 68 65 20 6c 61 62 5f | 44 69 72 65 63 74 50 61 |the lab_|DirectPa|
|00003220| 72 61 6d 44 69 73 70 61 | 74 63 68 20 72 6f 75 74 |ramDispa|tch rout|
|00003230| 69 6e 65 2e 0d 00 0c 2a | 18 04 48 6f 6f 6b 04 00 |ine....*|..Hook..|
|00003240| 29 1f 01 3a 0d 00 0a 2b | 29 18 2b 4f 53 45 72 72 |)..:...+|).+OSErr|
|00003250| 20 6c 61 62 5f 49 6e 73 | 74 61 6c 6c 41 45 4f 62 | lab_Ins|tallAEOb|
|00003260| 6a 65 63 74 44 69 73 70 | 61 74 63 68 28 20 76 6f |jectDisp|atch( vo|
|00003270| 69 64 20 29 3b 20 0d 00 | 0c 28 01 f9 00 6c 54 54 |id ); ..|.(...lTT|
|00003280| 68 69 73 20 68 6f 6f 6b | 20 69 73 20 72 65 73 70 |his hook| is resp|
|00003290| 6f 6e 73 69 62 6c 65 20 | 66 6f 72 20 69 6e 73 74 |onsible |for inst|
|000032a0| 61 6c 6c 69 6e 67 20 74 | 68 65 20 6c 61 62 5f 44 |alling t|he lab_D|
|000032b0| 69 72 65 63 74 50 61 72 | 61 6d 44 69 73 70 61 74 |irectPar|amDispat|
|000032c0| 63 68 20 72 6f 75 74 69 | 6e 65 20 69 6e 74 6f 20 |ch routi|ne into |
|000032d0| 74 68 65 2a 0c 52 41 70 | 70 6c 65 20 45 76 65 6e |the*.RAp|ple Even|
|000032e0| 74 20 4d 61 6e 61 67 65 | 72 d5 73 20 69 6e 74 65 |t Manage|r.s inte|
|000032f0| 72 6e 61 6c 20 74 61 62 | 6c 65 73 20 73 6f 20 74 |rnal tab|les so t|
|00003300| 68 61 74 20 69 74 20 77 | 69 6c 6c 20 67 65 74 20 |hat it w|ill get |
|00003310| 63 61 6c 6c 65 64 20 77 | 68 65 6e 65 76 65 72 20 |called w|henever |
|00003320| 61 6e 20 41 70 70 6c 65 | 2a 0c 54 65 76 65 6e 74 |an Apple|*.Tevent|
|00003330| 20 69 73 20 72 65 63 65 | 69 76 65 64 2e 20 54 68 | is rece|ived. Th|
|00003340| 65 20 65 76 65 6e 74 20 | 63 6c 61 73 73 20 73 68 |e event |class sh|
|00003350| 6f 75 6c 64 20 62 65 20 | d2 6b 41 45 43 6f 72 65 |ould be |.kAECore|
|00003360| 53 75 69 74 65 d3 20 28 | 6e 6f 74 20 74 6f 20 62 |Suite. (|not to b|
|00003370| 65 20 63 6f 6e 66 75 73 | 65 64 20 77 69 74 68 2a |e confus|ed with*|
|00003380| 0c 55 d2 6b 43 6f 72 65 | 45 76 65 6e 74 43 6c 61 |.U.kCore|EventCla|
|00003390| 73 73 d3 2c 20 77 68 69 | 63 68 20 69 73 20 74 68 |ss., whi|ch is th|
|000033a0| 65 20 63 6f 6e 73 74 61 | 6e 74 20 66 6f 72 20 74 |e consta|nt for t|
|000033b0| 68 65 20 34 20 52 65 71 | 75 69 72 65 64 20 65 76 |he 4 Req|uired ev|
|000033c0| 65 6e 74 73 29 2c 20 61 | 6e 64 20 74 68 65 20 65 |ents), a|nd the e|
|000033d0| 76 65 6e 74 20 49 44 2a | 0c 1f 73 68 6f 75 6c 64 |vent ID*|..should|
|000033e0| 20 62 65 20 74 68 65 20 | d4 2a 2a 2a 2a d5 20 77 | be the |.****. w|
|000033f0| 69 6c 64 20 63 61 72 64 | 2e 04 05 2a 18 17 49 6d |ild card|...*..Im|
|00003400| 70 6c 65 6d 65 6e 74 61 | 74 69 6f 6e 20 d2 52 65 |plementa|tion .Re|
|00003410| 63 69 70 65 d3 04 00 2a | 18 1a 41 64 64 20 74 68 |cipe...*|..Add th|
|00003420| 65 20 66 6f 6c 6c 6f 77 | 69 6e 67 20 63 6f 64 65 |e follow|ing code|
|00003430| 20 74 6f 20 04 01 29 7e | 1b 6c 61 62 5f 49 6e 73 | to ..)~|.lab_Ins|
|00003440| 74 61 6c 6c 41 45 4f 62 | 6a 65 63 74 44 69 73 70 |tallAEOb|jectDisp|
|00003450| 61 74 63 68 04 00 29 a2 | 01 3a 03 00 16 0d 00 0a |atch..).|.:......|
|00003460| 28 02 71 00 7e 0a 4f 53 | 45 72 72 20 65 72 72 3b |(.q.~.OS|Err err;|
|00003470| 2a 16 37 65 72 72 20 3d | 20 41 45 49 6e 73 74 61 |*.7err =| AEInsta|
|00003480| 6c 6c 45 76 65 6e 74 48 | 61 6e 64 6c 65 72 28 6b |llEventH|andler(k|
|00003490| 41 45 43 6f 72 65 53 75 | 69 74 65 2c 20 74 79 70 |AECoreSu|ite, typ|
|000034a0| 65 57 69 6c 64 43 61 72 | 64 2c 2b 36 0b 38 28 45 |eWildCar|d,+6.8(E|
|000034b0| 76 65 6e 74 48 61 6e 64 | 6c 65 72 50 72 6f 63 50 |ventHand|lerProcP|
|000034c0| 74 72 29 6c 61 62 5f 44 | 69 72 65 63 74 50 61 72 |tr)lab_D|irectPar|
|000034d0| 61 6d 44 69 73 70 61 74 | 63 68 2c 20 30 2c 20 66 |amDispat|ch, 0, f|
|000034e0| 61 6c 73 65 29 3b 28 02 | 9d 00 7e 0b 72 65 74 75 |alse);(.|..~.retu|
|000034f0| 72 6e 20 65 72 72 3b 03 | 00 14 0d 00 0c 28 02 ee |rn err;.|.....(..|
|00003500| 00 48 14 44 65 76 65 6c | 6f 70 65 72 20 55 6e 69 |.H.Devel|oper Uni|
|00003510| 76 65 72 73 69 74 79 29 | e0 02 2d 20 29 07 01 34 |versity)|..- )..4|
|00003520| 29 06 02 20 2d 29 95 18 | 52 65 67 69 73 74 72 79 |).. -)..|Registry|
|00003530| 20 2f 20 44 31 20 20 4c | 61 62 20 4e 6f 74 65 73 | / D1 L|ab Notes|
|00003540| ff 00 0c 00 00 00 00 02 | d7 02 23 11 01 0c 00 1e |........|..#.....|
|00003550| 00 1f 01 00 0a 00 00 00 | 00 03 15 02 5f 2c 00 08 |........|...._,..|
|00003560| 00 14 05 54 69 6d 65 73 | 03 00 14 04 01 0d 00 0e |...Times|........|
|00003570| 2e 00 04 00 00 00 00 2b | 48 4e 02 33 2e 29 24 26 |.......+|HN.3.)$&|
|00003580| 49 6d 70 6c 65 6d 65 6e | 74 20 74 68 65 20 4f 62 |Implemen|t the Ob|
|00003590| 6a 65 63 74 20 53 77 69 | 74 63 68 65 72 20 72 6f |ject Swi|tcher ro|
|000035a0| 75 74 69 6e 65 2e 2c 00 | 0a 00 16 07 43 6f 75 72 |utine.,.|....Cour|
|000035b0| 69 65 72 03 00 16 0d 00 | 0c 2b 12 19 05 48 6f 6f |ier.....|.+...Hoo|
|000035c0| 6b 3a 04 00 0d 00 09 2b | 36 16 1a 4f 53 45 72 72 |k:.....+|6..OSErr|
|000035d0| 20 6c 61 62 5f 53 65 6e | 64 41 45 54 6f 4f 62 6a | lab_Sen|dAEToObj|
|000035e0| 65 63 74 20 28 2a 0a 10 | 63 6f 6e 73 74 20 41 70 |ect (*..|const Ap|
|000035f0| 70 6c 65 45 76 65 6e 74 | 29 55 0a 2a 6d 65 73 73 |pleEvent|)U.*mess|
|00003600| 61 67 65 2c 20 29 44 14 | 2f 2f 31 2e 20 74 68 65 |age, )D.|//1. the|
|00003610| 20 69 6e 63 6f 6d 69 6e | 67 20 41 45 28 00 91 00 | incomin|g AE(...|
|00003620| b4 0a 41 70 70 6c 65 45 | 76 65 6e 74 29 55 08 2a |..AppleE|vent)U.*|
|00003630| 72 65 70 6c 79 2c 20 29 | 44 27 2f 2f 32 2e 20 72 |reply, )|D'//2. r|
|00003640| 65 70 6c 79 20 74 6f 20 | 73 65 6e 64 20 69 66 20 |eply to |send if |
|00003650| 6e 6f 74 20 61 20 d4 6e | 75 6c 6c d5 20 64 65 73 |not a .n|ull. des|
|00003660| 63 28 00 9b 00 b4 04 6c | 6f 6e 67 29 55 08 20 72 |c(.....l|ong)U. r|
|00003670| 65 66 43 6f 6e 2c 29 44 | 23 2f 2f 33 2e 20 65 76 |efCon,)D|#//3. ev|
|00003680| 65 6e 74 20 68 61 6e 64 | 6c 65 72 20 72 65 66 63 |ent hand|ler refc|
|00003690| 6f 6e 20 28 69 67 6e 6f | 72 65 64 29 28 00 a5 00 |on (igno|red)(...|
|000036a0| b4 0c 41 45 45 76 65 6e | 74 43 6c 61 73 73 29 55 |..AEEven|tClass)U|
|000036b0| 0a 20 63 6c 61 73 73 49 | 44 2c 20 29 44 24 2f 2f |. classI|D, )D$//|
|000036c0| 34 2e 20 41 45 20 63 6c | 61 73 73 49 44 20 28 61 |4. AE cl|assID (a|
|000036d0| 6c 77 61 79 73 20 d4 61 | 65 76 74 d5 20 68 65 72 |lways .a|evt. her|
|000036e0| 65 29 28 00 af 00 b4 09 | 41 45 45 76 65 6e 74 49 |e)(.....|AEEventI|
|000036f0| 44 29 55 09 20 65 76 65 | 6e 74 49 44 2c 29 44 26 |D)U. eve|ntID,)D&|
|00003700| 2f 2f 35 2e 20 41 45 20 | 65 76 65 6e 74 49 44 20 |//5. AE |eventID |
|00003710| 28 61 20 43 6f 72 65 20 | 53 75 69 74 65 20 49 44 |(a Core |Suite ID|
|00003720| 20 68 65 72 65 29 28 00 | b9 00 b4 08 44 65 73 63 | here)(.|....Desc|
|00003730| 54 79 70 65 29 55 37 20 | 64 69 73 70 61 74 63 68 |Type)U7 |dispatch|
|00003740| 43 6c 61 73 73 2c 20 2f | 2f 36 2e 20 63 6c 61 73 |Class, /|/6. clas|
|00003750| 73 20 49 44 20 6f 66 20 | 4f 62 6a 65 63 74 20 74 |s ID of |Object t|
|00003760| 6f 20 68 61 6e 64 6c 65 | 20 65 76 65 6e 74 28 00 |o handle| event(.|
|00003770| c3 00 b4 0c 63 6f 6e 73 | 74 20 41 45 44 65 73 63 |....cons|t AEDesc|
|00003780| 29 55 08 2a 6f 73 70 65 | 63 2c 20 29 44 19 2f 2f |)U.*ospe|c, )D.//|
|00003790| 37 2e 20 64 69 72 65 63 | 74 20 70 61 72 61 6d 20 |7. direc|t param |
|000037a0| 66 72 6f 6d 20 41 45 28 | 00 cd 00 b4 0c 63 6f 6e |from AE(|.....con|
|000037b0| 73 74 20 41 45 44 65 73 | 63 29 55 08 2a 74 6f 6b |st AEDes|c)U.*tok|
|000037c0| 65 6e 29 3b 29 44 22 2f | 2f 38 2e 20 74 6f 6b 65 |en);)D"/|/8. toke|
|000037d0| 6e 20 6f 62 74 61 69 6e | 65 64 20 66 72 6f 6d 20 |n obtain|ed from |
|000037e0| 41 45 52 65 73 6f 6c 76 | 65 03 00 14 0d 00 0c 28 |AEResolv|e......(|
|000037f0| 00 e4 00 6c 52 54 68 69 | 73 20 69 73 20 74 68 65 |...lRThi|s is the|
|00003800| 20 d2 4f 62 6a 65 63 74 | 20 53 77 69 74 63 68 65 | .Object| Switche|
|00003810| 72 d3 20 72 6f 75 74 69 | 6e 65 20 77 68 69 63 68 |r. routi|ne which|
|00003820| 20 63 61 6c 6c 73 20 74 | 68 65 20 43 6f 6d 6d 61 | calls t|he Comma|
|00003830| 6e 64 20 53 77 69 74 63 | 68 65 72 20 72 6f 75 74 |nd Switc|her rout|
|00003840| 69 6e 65 73 20 69 6e 2a | 0c 0c 65 61 63 68 20 6f |ines in*|..each o|
|00003850| 62 6a 65 63 74 2e 2a 18 | 51 54 68 65 72 65 20 69 |bject.*.|QThere i|
|00003860| 73 20 6f 6e 6c 79 20 6f | 6e 65 20 4f 62 6a 65 63 |s only o|ne Objec|
|00003870| 74 20 53 77 69 74 63 68 | 65 72 20 69 6e 20 61 6e |t Switch|er in an|
|00003880| 79 20 61 70 70 6c 69 63 | 61 74 69 6f 6e 2e 20 41 |y applic|ation. A|
|00003890| 73 20 73 75 63 68 2c 20 | 69 66 20 79 6f 75 20 61 |s such, |if you a|
|000038a0| 72 65 20 75 73 69 6e 67 | 20 61 2a 0c 50 70 72 6f |re using| a*.Ppro|
|000038b0| 63 65 64 75 72 61 6c 6c | 79 20 6f 72 69 65 6e 74 |cedurall|y orient|
|000038c0| 65 64 20 6c 61 6e 67 75 | 61 67 65 20 28 61 73 20 |ed langu|age (as |
|000038d0| 6f 70 70 6f 73 65 64 20 | 74 6f 20 61 6e 20 4f 62 |opposed |to an Ob|
|000038e0| 6a 65 63 74 20 4f 72 69 | 65 6e 74 65 64 20 50 72 |ject Ori|ented Pr|
|000038f0| 6f 67 72 61 6d 6d 69 6e | 67 20 6f 6e 65 2a 0c 53 |ogrammin|g one*.S|
|00003900| 73 75 63 68 20 61 73 20 | 43 2b 2b 20 6f 72 20 4f |such as |C++ or O|
|00003910| 62 6a 65 63 74 20 50 61 | 73 63 61 6c 29 2c 20 74 |bject Pa|scal), t|
|00003920| 68 69 73 20 72 6f 75 74 | 69 6e 65 20 6d 75 73 74 |his rout|ine must|
|00003930| 20 62 65 20 6d 6f 64 69 | 66 69 65 64 20 65 76 65 | be modi|fied eve|
|00003940| 72 79 20 74 69 6d 65 20 | 61 20 6e 65 77 20 41 70 |ry time |a new Ap|
|00003950| 70 6c 65 2a 0c 2b 45 76 | 65 6e 74 20 6f 62 6a 65 |ple*.+Ev|ent obje|
|00003960| 63 74 20 63 6c 61 73 73 | 20 69 73 20 61 64 64 65 |ct class| is adde|
|00003970| 64 20 74 6f 20 74 68 65 | 20 70 72 6f 67 72 61 6d |d to the| program|
|00003980| 2e 2a 18 53 54 68 65 20 | 6c 61 62 20 61 70 70 6c |.*.SThe |lab appl|
|00003990| 69 63 61 74 69 6f 6e 20 | 61 6c 72 65 61 64 79 20 |ication |already |
|000039a0| 69 6d 70 6c 65 6d 65 6e | 74 73 20 61 20 70 61 72 |implemen|ts a par|
|000039b0| 74 69 61 6c 20 6f 62 6a | 65 63 74 20 73 77 69 74 |tial obj|ect swit|
|000039c0| 63 68 65 72 2c 20 77 68 | 69 63 68 20 79 6f 75 20 |cher, wh|ich you |
|000039d0| 77 69 6c 6c 20 62 65 2a | 0c 4b 72 65 70 6c 61 63 |will be*|.Kreplac|
|000039e0| 69 6e 67 2e 20 54 68 69 | 73 20 6d 65 61 6e 73 20 |ing. Thi|s means |
|000039f0| 79 6f 75 72 20 63 6f 64 | 65 20 6d 75 73 74 20 61 |your cod|e must a|
|00003a00| 6c 73 6f 20 63 61 6c 6c | 20 74 68 65 20 73 68 65 |lso call| the she|
|00003a10| 6c 6c d5 73 20 43 6f 6d | 6d 61 6e 64 20 53 77 69 |ll.s Com|mand Swi|
|00003a20| 74 63 68 65 72 2a 0c 53 | 72 6f 75 74 69 6e 65 73 |tcher*.S|routines|
|00003a30| 2c 20 77 68 65 6e 20 61 | 6e 20 65 76 65 6e 74 20 |, when a|n event |
|00003a40| 69 73 20 62 65 69 6e 67 | 20 64 69 72 65 63 74 65 |is being| directe|
|00003a50| 64 20 74 6f 20 6f 6e 65 | 20 6f 66 20 74 68 65 20 |d to one| of the |
|00003a60| 73 68 65 6c 6c d5 73 20 | 6f 62 6a 65 63 74 20 63 |shell.s |object c|
|00003a70| 6c 61 73 73 65 73 2e 20 | 54 68 65 2a 0c 33 73 68 |lasses. |The*.3sh|
|00003a80| 65 6c 6c d5 73 20 63 6f | 6d 6d 61 6e 64 20 73 77 |ell.s co|mmand sw|
|00003a90| 69 74 63 68 65 72 20 72 | 6f 75 74 69 6e 65 73 20 |itcher r|outines |
|00003aa0| 61 72 65 20 6c 69 73 74 | 65 64 20 62 65 6c 6f 77 |are list|ed below|
|00003ab0| 2e 04 05 2a 18 17 49 6d | 70 6c 65 6d 65 6e 74 61 |...*..Im|plementa|
|00003ac0| 74 69 6f 6e 20 d2 52 65 | 63 69 70 65 d3 04 00 2b |tion .Re|cipe...+|
|00003ad0| 24 12 4f 31 2e 20 55 73 | 69 6e 67 20 61 20 73 77 |$.O1. Us|ing a sw|
|00003ae0| 69 74 63 68 20 73 74 61 | 74 65 6d 65 6e 74 2c 20 |itch sta|tement, |
|00003af0| 63 61 73 65 20 6f 66 66 | 20 6f 66 20 74 68 65 20 |case off| of the |
|00003b00| 64 69 73 70 61 74 63 68 | 20 63 6c 61 73 73 20 70 |dispatch| class p|
|00003b10| 61 72 61 6d 65 74 65 72 | 2c 20 61 6e 64 20 63 61 |arameter|, and ca|
|00003b20| 6c 6c 2b 12 0c 29 74 68 | 65 20 61 70 70 72 6f 70 |ll+..)th|e approp|
|00003b30| 72 69 61 74 65 20 43 6f | 6d 6d 61 6e 64 20 53 77 |riate Co|mmand Sw|
|00003b40| 69 74 63 68 65 72 20 72 | 6f 75 74 69 6e 65 2e 2a |itcher r|outine.*|
|00003b50| 18 39 49 66 20 74 68 65 | 20 63 6c 61 73 73 20 69 |.9If the| class i|
|00003b60| 73 6e d5 74 20 6f 6e 65 | 20 6f 66 20 74 68 65 20 |sn.t one| of the |
|00003b70| 63 6c 61 73 73 65 73 20 | 66 6f 75 6e 64 20 62 65 |classes |found be|
|00003b80| 6c 6f 77 2c 20 72 65 74 | 75 72 6e 04 01 2a 0c 0f |low, ret|urn..*..|
|00003b90| 65 72 72 4e 6f 53 75 63 | 68 4f 62 6a 65 63 74 04 |errNoSuc|hObject.|
|00003ba0| 00 29 61 01 2e 04 01 28 | 01 f4 00 94 05 43 6c 61 |.)a....(|.....Cla|
|00003bb0| 73 73 29 c2 06 41 63 74 | 69 6f 6e 07 00 02 00 01 |ss)..Act|ion.....|
|00003bc0| 22 01 dd 00 67 01 00 07 | 00 01 00 02 22 01 dd 00 |"...g...|...."...|
|00003bd0| 67 00 01 07 00 02 00 01 | 22 01 dd 00 69 7b 00 22 |g.......|"...i{."|
|00003be0| 01 dd 00 e5 01 00 20 01 | dd 00 e7 01 dd 01 e9 22 |...... .|......."|
|00003bf0| 01 dd 01 ea 01 00 07 00 | 01 00 02 22 01 dd 01 ea |........|..."....|
|00003c00| 00 01 22 01 df 00 67 00 | 17 22 01 df 01 ea 00 17 |.."...g.|."......|
|00003c10| 04 00 28 02 0d 00 82 06 | d4 6e 75 6c 6c d5 0a 00 |..(.....|.null...|
|00003c20| 00 00 00 00 00 00 00 34 | 02 10 00 68 02 28 00 e5 |.......4|...h.(..|
|00003c30| 29 71 2c 63 61 6c 6c 20 | 63 41 70 70 6c 69 63 61 |)q,call |cApplica|
|00003c40| 74 69 6f 6e d5 73 20 63 | 6f 6d 6d 61 6e 64 20 73 |tion.s c|ommand s|
|00003c50| 77 69 74 63 68 65 72 20 | 72 6f 75 74 69 6e 65 2a |witcher |routine*|
|00003c60| 0c 13 28 41 70 70 5f 41 | 45 5f 44 69 73 70 61 74 |..(App_A|E_Dispat|
|00003c70| 63 68 65 72 29 22 01 f7 | 00 67 00 00 07 00 01 00 |cher)"..|.g......|
|00003c80| 01 22 01 f7 00 69 7b 00 | 22 01 f7 00 e5 00 00 20 |."...i{.|"...... |
|00003c90| 01 f7 00 e6 01 f7 01 e9 | 07 00 01 00 02 22 01 f7 |........|....."..|
|00003ca0| 01 ea 00 00 22 01 f8 00 | 67 00 2f 22 01 f8 01 ea |...."...|g./"....|
|00003cb0| 00 2f 28 02 38 00 82 0b | 63 57 69 6e 64 6f 77 20 |./(.8...|cWindow |
|00003cc0| 61 6e 64 2a 0c 09 63 44 | 6f 63 75 6d 65 6e 74 34 |and*..cD|ocument4|
|00003cd0| 02 47 00 68 02 53 00 e5 | 28 02 38 00 f3 26 63 61 |.G.h.S..|(.8..&ca|
|00003ce0| 6c 6c 20 63 57 69 6e 64 | 6f 77 d5 73 20 63 6f 6d |ll cWind|ow.s com|
|00003cf0| 6d 61 6e 64 20 73 77 69 | 74 63 68 65 72 20 6f 75 |mand swi|tcher ou|
|00003d00| 74 69 6e 65 2a 0c 13 28 | 57 69 6e 5f 41 45 5f 44 |tine*..(|Win_AE_D|
|00003d10| 69 73 70 61 74 63 68 65 | 72 29 22 02 28 00 67 00 |ispatche|r)".(.g.|
|00003d20| 00 07 00 01 00 01 22 02 | 28 00 69 7b 00 22 02 28 |......".|(.i{.".(|
|00003d30| 00 e5 00 00 20 02 28 00 | e6 02 28 01 e9 07 00 01 |.... .(.|..(.....|
|00003d40| 00 02 22 02 28 01 ea 00 | 00 22 02 29 00 67 00 29 |..".(...|.".).g.)|
|00003d50| 22 02 29 01 ea 00 29 28 | 02 63 00 82 0c 63 41 70 |".)...)(|.c...cAp|
|00003d60| 70 6f 69 6e 74 6d 65 6e | 74 34 02 66 00 68 02 72 |pointmen|t4.f.h.r|
|00003d70| 00 e5 29 71 05 63 61 6c | 6c 20 04 01 29 13 11 6c |..)q.cal|l ..)..l|
|00003d80| 61 62 5f 41 45 5f 44 69 | 73 70 61 74 63 68 65 72 |ab_AE_Di|spatcher|
|00003d90| 22 02 53 00 67 00 00 07 | 00 01 00 01 22 02 53 00 |".S.g...|....".S.|
|00003da0| 69 7b 00 22 02 53 00 e5 | 00 00 20 02 53 00 e6 02 |i{.".S..|.. .S...|
|00003db0| 53 01 e9 07 00 01 00 02 | 22 02 53 01 ea 00 00 22 |S.......|".S...."|
|00003dc0| 02 54 00 67 00 1d 07 00 | 02 00 01 22 02 72 00 67 |.T.g....|...".r.g|
|00003dd0| 01 00 07 00 01 00 02 22 | 02 72 00 67 00 01 07 00 |......."|.r.g....|
|00003de0| 02 00 01 22 02 72 00 69 | 7b 00 22 02 72 00 e5 01 |...".r.i|{.".r...|
|00003df0| 00 20 02 72 00 e7 02 72 | 01 e9 07 00 01 00 02 22 |. .r...r|......."|
|00003e00| 02 54 01 ea 00 1d 07 00 | 02 00 01 22 02 72 01 ea |.T......|...".r..|
|00003e10| 01 00 07 00 01 00 02 22 | 02 72 01 ea 00 01 04 05 |......."|.r......|
|00003e20| 28 02 89 00 6c 07 54 65 | 73 74 69 6e 67 04 00 29 |(...l.Te|sting..)|
|00003e30| 2a 02 3a 20 29 0c 34 42 | 65 66 6f 72 65 20 79 6f |*.: ).4B|efore yo|
|00003e40| 75 20 74 65 73 74 20 74 | 68 69 73 20 6c 61 62 2c |u test t|his lab,|
|00003e50| 20 77 65 20 73 75 67 67 | 65 73 74 20 74 68 61 74 | we sugg|est that|
|00003e60| 20 79 6f 75 20 61 64 64 | 20 61 20 04 01 29 f1 0b | you add| a ..)..|
|00003e70| 53 68 6f 77 4d 65 73 73 | 61 67 65 04 00 29 50 0b |ShowMess|age..)P.|
|00003e80| 20 63 6f 6d 6d 61 6e 64 | 20 74 6f 28 02 95 00 a2 | command| to(....|
|00003e90| 14 63 41 70 70 6f 69 6e | 74 6d 65 6e 74 d5 73 20 |.cAppoin|tment.s |
|00003ea0| 63 61 73 65 2e 2a 18 4c | 57 68 65 6e 20 79 6f 75 |case.*.L|When you|
|00003eb0| 20 73 65 6c 65 63 74 20 | 74 68 69 73 20 6c 61 62 | select |this lab|
|00003ec0| 20 66 72 6f 6d 20 74 68 | 65 20 4c 61 62 54 65 73 | from th|e LabTes|
|00003ed0| 74 20 6d 65 6e 75 20 61 | 6e 64 20 63 68 6f 6f 73 |t menu a|nd choos|
|00003ee0| 65 20 6f 6e 65 20 6f 66 | 20 74 68 65 20 62 75 74 |e one of| the but|
|00003ef0| 74 6f 6e 73 2a 0c 50 69 | 6e 20 74 68 65 20 64 69 |tons*.Pi|n the di|
|00003f00| 61 6c 6f 67 2c 20 74 68 | 65 20 74 65 73 74 69 6e |alog, th|e testin|
|00003f10| 67 20 63 6f 64 65 20 77 | 69 6c 6c 20 73 65 6e 64 |g code w|ill send|
|00003f20| 20 61 20 73 70 65 63 69 | 61 6c 20 47 65 74 20 44 | a speci|al Get D|
|00003f30| 61 74 61 20 61 70 70 6c | 65 20 65 76 65 6e 74 20 |ata appl|e event |
|00003f40| 74 6f 20 79 6f 75 72 2a | 0c 4e 61 70 70 6c 69 63 |to your*|.Napplic|
|00003f50| 61 74 69 6f 6e 2e 20 28 | 54 68 69 73 20 65 76 65 |ation. (|This eve|
|00003f60| 6e 74 20 63 6f 6e 74 61 | 69 6e 73 20 61 20 70 61 |nt conta|ins a pa|
|00003f70| 72 61 6d 65 74 65 72 20 | 77 68 69 63 68 20 63 61 |rameter |which ca|
|00003f80| 75 73 65 73 20 74 68 65 | 20 41 70 70 6c 69 63 61 |uses the| Applica|
|00003f90| 74 69 6f 6e 20 61 6e 64 | 2a 0c 35 57 69 6e 64 6f |tion and|*.5Windo|
|00003fa0| 77 20 64 69 73 70 61 74 | 63 68 65 72 73 20 64 6f |w dispat|chers do|
|00003fb0| 20 64 69 73 70 6c 61 79 | 20 61 20 6d 65 73 73 61 | display| a messa|
|00003fc0| 67 65 20 77 68 65 6e 20 | 63 61 6c 6c 65 64 2e 29 |ge when |called.)|
|00003fd0| 28 02 ee 00 48 14 44 65 | 76 65 6c 6f 70 65 72 20 |(...H.De|veloper |
|00003fe0| 55 6e 69 76 65 72 73 69 | 74 79 29 e0 02 2d 20 29 |Universi|ty)..- )|
|00003ff0| 07 01 35 29 06 02 20 2d | 29 95 18 52 65 67 69 73 |..5).. -|)..Regis|
|00004000| 74 72 79 20 2f 20 44 31 | 20 20 4c 61 62 20 4e 6f |try / D1| Lab No|
|00004010| 74 65 73 ff 00 0c 00 00 | 00 00 02 d7 02 23 11 01 |tes.....|.....#..|
|00004020| 0c 00 1e 00 1f 01 00 0a | 00 00 00 00 03 15 02 5f |........|......._|
|00004030| 2c 00 08 00 14 05 54 69 | 6d 65 73 03 00 14 0d 00 |,.....Ti|mes.....|
|00004040| 0c 2e 00 04 00 00 00 00 | 2b a2 2d 51 49 66 20 61 |........|+.-QIf a|
|00004050| 20 d4 6e 75 6c 6c d5 2c | 20 63 57 69 6e 64 6f 77 | .null.,| cWindow|
|00004060| 2c 20 6f 72 20 63 44 6f | 63 75 6d 65 6e 74 20 64 |, or cDo|cument d|
|00004070| 69 73 70 61 74 63 68 65 | 72 20 69 73 20 63 61 6c |ispatche|r is cal|
|00004080| 6c 65 64 20 63 6f 72 72 | 65 63 74 6c 79 2c 20 79 |led corr|ectly, y|
|00004090| 6f 75 20 77 69 6c 6c 20 | 67 65 74 20 61 2a 0c 46 |ou will |get a*.F|
|000040a0| 6d 65 73 73 61 67 65 20 | 77 69 6e 64 6f 77 20 72 |message |window r|
|000040b0| 65 70 6f 72 74 69 6e 67 | 20 74 68 65 20 73 75 63 |eporting| the suc|
|000040c0| 63 65 73 73 66 75 6c 20 | 63 6f 6d 70 6c 65 74 69 |cessful |completi|
|000040d0| 6f 6e 20 6f 66 20 74 68 | 65 20 74 65 73 74 2e 20 |on of th|e test. |
|000040e0| 49 66 20 74 68 65 2a 0c | 4a 63 41 70 70 6c 69 63 |If the*.|JcApplic|
|000040f0| 61 74 69 6f 6e 20 64 69 | 73 70 61 74 63 68 65 72 |ation di|spatcher|
|00004100| 20 69 73 20 63 61 6c 6c | 65 64 2c 20 79 6f 75 20 | is call|ed, you |
|00004110| 77 69 6c 6c 20 67 65 74 | 20 61 20 6d 65 73 73 61 |will get| a messa|
|00004120| 67 65 20 6f 6e 6c 79 20 | 69 66 20 79 6f 75 20 63 |ge only |if you c|
|00004130| 61 6c 6c 04 01 2a 0c 0b | 53 68 6f 77 4d 65 73 73 |all..*..|ShowMess|
|00004140| 61 67 65 04 00 29 50 0a | 20 79 6f 75 72 73 65 6c |age..)P.| yoursel|
|00004150| 66 2e 04 05 28 00 69 00 | 6c 06 45 72 72 6f 72 73 |f...(.i.|l.Errors|
|00004160| 04 00 29 24 01 3a 04 01 | 29 24 14 65 72 72 41 45 |..)$.:..|)$.errAE|
|00004170| 45 76 65 6e 74 4e 6f 74 | 48 61 6e 64 6c 65 64 04 |EventNot|Handled.|
|00004180| 00 29 85 05 20 61 6e 64 | 20 04 01 29 17 0f 65 72 |.).. and| ..)..er|
|00004190| 72 4e 6f 53 75 63 68 4f | 62 6a 65 63 74 04 05 28 |rNoSuchO|bject..(|
|000041a0| 00 81 00 6c 18 52 65 71 | 75 69 72 65 64 20 53 68 |...l.Req|uired Sh|
|000041b0| 65 6c 6c 20 55 74 69 6c | 69 74 69 65 73 04 00 29 |ell Util|ities..)|
|000041c0| 86 01 3a 2c 00 0a 00 16 | 07 43 6f 75 72 69 65 72 |..:,....|.Courier|
|000041d0| 03 00 16 0d 00 09 28 00 | 98 00 7e 4e 4f 53 45 72 |......(.|..~NOSEr|
|000041e0| 72 20 41 70 70 5f 41 45 | 5f 44 69 73 70 61 74 63 |r App_AE|_Dispatc|
|000041f0| 68 65 72 28 63 6f 6e 73 | 74 20 41 70 70 6c 65 45 |her(cons|t AppleE|
|00004200| 76 65 6e 74 20 2a 6d 73 | 67 2c 20 41 70 70 6c 65 |vent *ms|g, Apple|
|00004210| 45 76 65 6e 74 20 2a 72 | 65 70 6c 79 2c 20 6c 6f |Event *r|eply, lo|
|00004220| 6e 67 20 72 65 66 63 6f | 6e 2c 2b 5a 0a 3d 41 45 |ng refco|n,+Z.=AE|
|00004230| 45 76 65 6e 74 43 6c 61 | 73 73 20 63 6c 61 73 73 |EventCla|ss class|
|00004240| 49 44 2c 20 41 45 45 76 | 65 6e 74 49 44 20 65 76 |ID, AEEv|entID ev|
|00004250| 65 6e 74 49 44 2c 20 63 | 6f 6e 73 74 20 41 45 44 |entID, c|onst AED|
|00004260| 65 73 63 20 2a 6f 73 70 | 65 63 2c 2a 0a 39 63 6f |esc *osp|ec,*.9co|
|00004270| 6e 73 74 20 41 45 44 65 | 73 63 20 2a 74 6f 6b 65 |nst AEDe|sc *toke|
|00004280| 6e 29 3b 20 20 20 20 2f | 2f 20 63 41 70 70 6c 69 |n); /|/ cAppli|
|00004290| 63 61 74 69 6f 6e 20 43 | 6f 6d 6d 61 6e 64 20 53 |cation C|ommand S|
|000042a0| 77 69 74 63 68 65 72 28 | 00 c2 00 7e 4e 4f 53 45 |witcher(|...~NOSE|
|000042b0| 72 72 20 57 69 6e 5f 41 | 45 5f 44 69 73 70 61 74 |rr Win_A|E_Dispat|
|000042c0| 63 68 65 72 28 63 6f 6e | 73 74 20 41 70 70 6c 65 |cher(con|st Apple|
|000042d0| 45 76 65 6e 74 20 2a 6d | 73 67 2c 20 41 70 70 6c |Event *m|sg, Appl|
|000042e0| 65 45 76 65 6e 74 20 2a | 72 65 70 6c 79 2c 20 6c |eEvent *|reply, l|
|000042f0| 6f 6e 67 20 72 65 66 63 | 6f 6e 2c 2b 5a 0a 3d 41 |ong refc|on,+Z.=A|
|00004300| 45 45 76 65 6e 74 43 6c | 61 73 73 20 63 6c 61 73 |EEventCl|ass clas|
|00004310| 73 49 44 2c 20 41 45 45 | 76 65 6e 74 49 44 20 65 |sID, AEE|ventID e|
|00004320| 76 65 6e 74 49 44 2c 20 | 63 6f 6e 73 74 20 41 45 |ventID, |const AE|
|00004330| 44 65 73 63 20 2a 6f 73 | 70 65 63 2c 2a 0a 39 63 |Desc *os|pec,*.9c|
|00004340| 6f 6e 73 74 20 41 45 44 | 65 73 63 20 2a 74 6f 6b |onst AED|esc *tok|
|00004350| 65 6e 29 3b 20 20 20 2f | 2f 20 63 57 69 6e 64 6f |en); /|/ cWindo|
|00004360| 77 20 61 6e 64 20 63 44 | 6f 63 75 6d 65 6e 74 20 |w and cD|ocument |
|00004370| 53 77 69 74 63 68 65 72 | 03 00 14 04 05 0d 00 0c |Switcher|........|
|00004380| 28 01 03 00 6c 18 4f 70 | 74 69 6f 6e 61 6c 20 53 |(...l.Op|tional S|
|00004390| 68 65 6c 6c 20 55 74 69 | 6c 69 74 69 65 73 04 00 |hell Uti|lities..|
|000043a0| 29 83 01 3a 03 00 16 0d | 00 09 28 01 1a 00 7e 20 |)..:....|..(...~ |
|000043b0| 76 6f 69 64 20 53 68 6f | 77 4d 65 73 73 61 67 65 |void Sho|wMessage|
|000043c0| 20 28 63 68 61 72 20 2a | 6d 65 73 73 61 67 65 29 | (char *|message)|
|000043d0| 03 00 14 04 05 0d 00 0c | 28 01 31 00 6c 14 52 65 |........|(.1.l.Re|
|000043e0| 71 75 69 72 65 64 20 4f | 53 20 52 6f 75 74 69 6e |quired O|S Routin|
|000043f0| 65 73 04 00 29 7e 01 3a | 03 00 16 0d 00 09 28 01 |es..)~.:|......(.|
|00004400| 48 00 7e 04 6e 6f 6e 65 | 03 00 14 04 01 0d 00 0e |H.~.none|........|
|00004410| 28 01 68 00 6c 37 59 6f | 75 20 68 61 76 65 20 6e |(.h.l7Yo|u have n|
|00004420| 6f 77 20 63 6f 6d 70 6c | 65 74 65 64 20 74 68 65 |ow compl|eted the|
|00004430| 20 69 6d 70 6c 65 6d 65 | 6e 74 61 74 69 6f 6e 20 | impleme|ntation |
|00004440| 6f 66 20 74 68 65 20 4f | 62 6a 65 63 74 2a 0f 38 |of the O|bject*.8|
|00004450| 44 69 73 70 61 74 63 68 | 65 72 20 70 61 72 74 20 |Dispatch|er part |
|00004460| 6f 66 20 61 20 52 65 67 | 69 73 74 72 79 20 65 76 |of a Reg|istry ev|
|00004470| 65 6e 74 20 68 61 6e 64 | 6c 65 72 2e 20 20 59 6f |ent hand|ler. Yo|
|00004480| 75 20 73 68 6f 75 6c 64 | 2a 0f 29 63 6f 6e 74 69 |u should|*.)conti|
|00004490| 6e 75 65 20 6f 6e 20 77 | 69 74 68 20 52 65 67 69 |nue on w|ith Regi|
|000044a0| 73 74 72 79 20 6c 61 62 | 20 44 32 2c 20 50 61 72 |stry lab| D2, Par|
|000044b0| 74 20 31 2e 04 00 0d 00 | 0c 28 02 ee 00 48 14 44 |t 1.....|.(...H.D|
|000044c0| 65 76 65 6c 6f 70 65 72 | 20 55 6e 69 76 65 72 73 |eveloper| Univers|
|000044d0| 69 74 79 29 e0 02 2d 20 | 29 07 01 36 29 06 02 20 |ity)..- |)..6).. |
|000044e0| 2d 29 95 18 52 65 67 69 | 73 74 72 79 20 2f 20 44 |-)..Regi|stry / D|
|000044f0| 31 20 20 4c 61 62 20 4e | 6f 74 65 73 ff 00 0c 00 |1 Lab N|otes....|
|00004500| 00 00 00 02 d7 02 23 11 | 01 0c 00 1e 00 1f 01 00 |......#.|........|
|00004510| 0a 00 00 00 00 03 15 02 | 5f 2c 00 08 00 14 05 54 |........|_,.....T|
|00004520| 69 6d 65 73 03 00 14 04 | 01 0d 00 0e 2e 00 04 00 |imes....|........|
|00004530| 00 00 00 2b 6c 30 02 34 | 2e 29 24 30 49 6d 70 6c |...+l0.4|.)$0Impl|
|00004540| 65 6d 65 6e 74 20 74 68 | 65 20 6c 61 62 5f 43 72 |ement th|e lab_Cr|
|00004550| 65 61 74 65 45 6c 65 6d | 65 6e 74 44 69 73 70 61 |eateElem|entDispa|
|00004560| 74 63 68 20 72 6f 75 74 | 69 6e 65 2e 2c 00 0a 00 |tch rout|ine.,...|
|00004570| 16 07 43 6f 75 72 69 65 | 72 03 00 16 04 02 0d 00 |..Courie|r.......|
|00004580| 0c 28 00 4f 00 6c 39 4e | 6f 74 65 3a 20 54 68 69 |.(.O.l9N|ote: Thi|
|00004590| 73 20 72 6f 75 74 69 6e | 65 20 69 73 20 75 73 65 |s routin|e is use|
|000045a0| 64 20 62 79 20 52 65 67 | 69 73 74 72 79 2f 44 32 |d by Reg|istry/D2|
|000045b0| 2c 20 50 61 72 74 20 34 | 20 28 43 72 65 61 74 65 |, Part 4| (Create|
|000045c0| 2a 12 2b 45 6c 65 6d 65 | 6e 74 29 2c 20 61 6e 64 |*.+Eleme|nt), and|
|000045d0| 20 72 65 71 75 69 72 65 | 73 20 74 68 61 74 20 6c | require|s that l|
|000045e0| 61 62 20 66 6f 72 20 74 | 65 73 74 69 6e 67 04 01 |ab for t|esting..|
|000045f0| 2a 1e 04 48 6f 6f 6b 04 | 00 29 20 01 3a 0d 00 0a |*..Hook.|.) .:...|
|00004600| 2b 16 1e 27 70 61 73 63 | 61 6c 20 4f 53 45 72 72 |+..'pasc|al OSErr|
|00004610| 20 6c 61 62 5f 43 72 65 | 61 74 65 45 6c 65 6d 65 | lab_Cre|ateEleme|
|00004620| 6e 74 44 69 73 70 61 74 | 63 68 28 04 01 2b 12 12 |ntDispat|ch(..+..|
|00004630| 0a 41 70 70 6c 65 45 76 | 65 6e 74 04 00 29 46 0a |.AppleEv|ent..)F.|
|00004640| 20 2a 6d 65 73 73 61 67 | 65 2c 04 01 28 00 c1 00 | *messag|e,..(...|
|00004650| b4 0a 41 70 70 6c 65 45 | 76 65 6e 74 04 00 29 46 |..AppleE|vent..)F|
|00004660| 08 20 2a 72 65 70 6c 79 | 2c 28 00 d3 00 b4 0d 6c |. *reply|,(.....l|
|00004670| 6f 6e 67 20 72 65 66 63 | 6f 6e 29 3b 03 00 14 0d |ong refc|on);....|
|00004680| 00 0c 28 00 ea 00 6c 53 | 54 68 65 20 43 72 65 61 |..(...lS|The Crea|
|00004690| 74 65 20 45 6c 65 6d 65 | 6e 74 20 63 6f 72 65 20 |te Eleme|nt core |
|000046a0| 65 76 65 6e 74 20 64 69 | 66 66 65 72 73 20 66 72 |event di|ffers fr|
|000046b0| 6f 6d 20 74 68 65 20 6f | 74 68 65 72 20 43 6f 72 |om the o|ther Cor|
|000046c0| 65 20 65 76 65 6e 74 73 | 2c 20 69 6e 20 74 68 61 |e events|, in tha|
|000046d0| 74 20 69 74 20 68 61 73 | 20 6e 6f 2a 0c 56 64 69 |t it has| no*.Vdi|
|000046e0| 72 65 63 74 20 70 61 72 | 61 6d 65 74 65 72 20 61 |rect par|ameter a|
|000046f0| 6e 64 20 64 6f 65 73 20 | 6e 6f 74 20 63 6f 6e 74 |nd does |not cont|
|00004700| 61 69 6e 20 61 6e 79 20 | 6f 62 6a 65 63 74 20 73 |ain any |object s|
|00004710| 70 65 63 69 66 69 65 72 | 73 20 69 6e 20 74 68 65 |pecifier|s in the|
|00004720| 20 75 73 75 61 6c 20 70 | 6c 61 63 65 73 2e 20 54 | usual p|laces. T|
|00004730| 68 65 73 65 2a 0c 4d 64 | 69 66 66 65 72 65 6e 63 |hese*.Md|ifferenc|
|00004740| 65 73 20 72 65 71 75 69 | 72 65 20 74 68 61 74 20 |es requi|re that |
|00004750| 43 72 65 61 74 65 20 45 | 6c 65 6d 65 6e 74 20 65 |Create E|lement e|
|00004760| 76 65 6e 74 73 20 62 65 | 20 73 70 65 63 69 61 6c |vents be| special|
|00004770| 2d 63 61 73 65 64 20 62 | 79 20 74 68 65 20 4f 62 |-cased b|y the Ob|
|00004780| 6a 65 63 74 2a 0c 51 44 | 69 73 70 61 74 63 68 65 |ject*.QD|ispatche|
|00004790| 72 2e 20 57 65 20 77 69 | 6c 6c 20 68 61 6e 64 6c |r. We wi|ll handl|
|000047a0| 65 20 74 68 69 73 20 72 | 65 71 75 69 72 65 6d 65 |e this r|equireme|
|000047b0| 6e 74 20 62 79 20 77 72 | 69 74 69 6e 67 20 61 6e |nt by wr|iting an|
|000047c0| 20 6f 62 6a 65 63 74 20 | 64 69 73 70 61 74 63 68 | object |dispatch|
|000047d0| 20 72 6f 75 74 69 6e 65 | 2a 0d 1f 73 70 65 63 69 | routine|*..speci|
|000047e0| 61 6c 69 7a 65 64 20 66 | 6f 72 20 43 72 65 61 74 |alized f|or Creat|
|000047f0| 65 20 45 6c 65 6d 65 6e | 74 2e 0d 00 09 28 01 18 |e Elemen|t....(..|
|00004800| 00 fe 01 33 0d 00 0c 28 | 01 33 00 6c 44 54 68 65 |...3...(|.3.lDThe|
|00004810| 20 66 69 72 73 74 20 70 | 61 72 61 6d 65 74 65 72 | first p|arameter|
|00004820| 20 6f 66 20 61 20 43 72 | 65 61 74 65 20 45 6c 65 | of a Cr|eate Ele|
|00004830| 6d 65 6e 74 20 65 76 65 | 6e 74 20 69 73 20 61 20 |ment eve|nt is a |
|00004840| 73 74 72 75 63 74 75 72 | 65 20 6f 66 20 74 79 70 |structur|e of typ|
|00004850| 65 2a 0d 12 d2 74 79 70 | 65 49 6e 73 65 72 74 69 |e*...typ|eInserti|
|00004860| 6f 6e 4c 6f 63 2e 0d 00 | 09 28 01 3d 00 c5 01 33 |onLoc...|.(.=...3|
|00004870| 0d 00 0c 2b 05 03 3c d3 | 2c 20 77 68 69 63 68 20 |...+..<.|, which |
|00004880| 69 73 20 73 74 6f 72 65 | 64 20 75 6e 64 65 72 20 |is store|d under |
|00004890| 74 68 65 20 6b 65 79 77 | 6f 72 64 20 d2 6b 65 79 |the keyw|ord .key|
|000048a0| 41 45 49 6e 73 65 72 74 | 48 65 72 65 d3 2e 20 20 |AEInsert|Here.. |
|000048b0| 59 6f 75 28 01 4c 00 6c | 50 77 69 6c 6c 20 6e 65 |You(.L.l|Pwill ne|
|000048c0| 65 64 20 74 6f 20 65 78 | 74 72 61 63 74 20 74 68 |ed to ex|tract th|
|000048d0| 69 73 20 73 74 72 75 63 | 74 75 72 65 2c 20 63 6f |is struc|ture, co|
|000048e0| 65 72 63 65 20 69 74 20 | 69 6e 74 6f 20 61 6e 20 |erce it |into an |
|000048f0| 41 45 52 65 63 6f 72 64 | 2c 20 61 6e 64 20 65 78 |AERecord|, and ex|
|00004900| 74 72 61 63 74 20 74 68 | 65 2a 0c 4b 66 6f 6c 6c |tract th|e*.Kfoll|
|00004910| 6f 77 69 6e 67 20 66 69 | 65 6c 64 73 3a 20 6b 65 |owing fi|elds: ke|
|00004920| 79 41 45 4f 62 6a 65 63 | 74 43 6c 61 73 73 2c 20 |yAEObjec|tClass, |
|00004930| 77 68 69 63 68 20 63 6f | 6e 74 61 69 6e 73 20 61 |which co|ntains a|
|00004940| 6e 20 6f 62 6a 65 63 74 | 20 73 70 65 63 69 66 69 |n object| specifi|
|00004950| 65 72 2c 20 61 6e 64 2a | 0c 32 6b 65 79 41 45 50 |er, and*|.2keyAEP|
|00004960| 6f 73 69 74 69 6f 6e 20 | 77 68 69 63 68 20 63 6f |osition |which co|
|00004970| 6e 74 61 69 6e 73 20 61 | 20 34 20 62 79 74 65 20 |ntains a| 4 byte |
|00004980| 65 6e 75 6d 65 72 61 74 | 69 6f 6e 2e 04 02 2a 18 |enumerat|ion...*.|
|00004990| 57 50 6c 65 61 73 65 20 | 6c 6f 6f 6b 20 61 74 20 |WPlease |look at |
|000049a0| 74 68 65 20 64 65 66 69 | 6e 69 74 69 6f 6e 20 6f |the defi|nition o|
|000049b0| 66 20 d2 74 79 70 65 49 | 6e 73 65 72 74 69 6f 6e |f .typeI|nsertion|
|000049c0| 4c 6f 63 d3 20 69 6e 20 | 74 68 65 20 41 70 70 6c |Loc. in |the Appl|
|000049d0| 65 20 45 76 65 6e 74 73 | 20 52 65 67 69 73 74 72 |e Events| Registr|
|000049e0| 79 20 62 65 66 6f 72 65 | 2a 0c 14 72 65 61 64 69 |y before|*..readi|
|000049f0| 6e 67 20 61 6e 79 20 66 | 61 72 74 68 65 72 2e 04 |ng any f|arther..|
|00004a00| 00 2a 18 56 54 68 65 20 | 6f 74 68 65 72 20 70 61 |.*.VThe |other pa|
|00004a10| 72 61 6d 65 74 65 72 20 | 73 70 65 63 69 66 69 65 |rameter |specifie|
|00004a20| 73 20 74 68 65 20 63 6c | 61 73 73 20 6f 66 20 6f |s the cl|ass of o|
|00004a30| 62 6a 65 63 74 20 74 6f | 20 62 65 20 63 72 65 61 |bject to| be crea|
|00004a40| 74 65 64 2e 20 54 68 69 | 73 20 70 61 72 61 6d 65 |ted. Thi|s parame|
|00004a50| 74 65 72 2c 20 77 68 69 | 63 68 2a 0c 42 69 73 20 |ter, whi|ch*.Bis |
|00004a60| 6f 66 20 74 79 70 65 20 | d2 74 79 70 65 54 79 70 |of type |.typeTyp|
|00004a70| 65 d3 2c 20 69 73 20 73 | 74 6f 72 65 64 20 75 6e |e., is s|tored un|
|00004a80| 64 65 72 20 74 68 65 20 | 6b 65 79 20 d2 6b 65 79 |der the |key .key|
|00004a90| 41 45 4f 62 6a 65 63 74 | 43 6c 61 73 73 d3 2e 04 |AEObject|Class...|
|00004aa0| 05 2a 18 17 49 6d 70 6c | 65 6d 65 6e 74 61 74 69 |.*..Impl|ementati|
|00004ab0| 6f 6e 20 d2 52 65 63 69 | 70 65 d3 04 00 2b 24 12 |on .Reci|pe...+$.|
|00004ac0| 02 31 2e 29 12 2f 47 65 | 74 20 74 68 65 20 65 76 |.1.)./Ge|t the ev|
|00004ad0| 65 6e 74 20 63 6c 61 73 | 73 20 61 6e 64 20 49 44 |ent clas|s and ID|
|00004ae0| 2c 20 6a 75 73 74 20 61 | 73 20 79 6f 75 20 64 69 |, just a|s you di|
|00004af0| 64 20 66 6f 72 04 01 2a | 0c 17 6c 61 62 5f 44 69 |d for..*|..lab_Di|
|00004b00| 72 65 63 74 50 61 72 61 | 6d 44 69 73 70 61 74 63 |rectPara|mDispatc|
|00004b10| 68 04 00 29 8e 01 2e 28 | 01 f4 00 90 02 32 2e 29 |h..)...(|.....2.)|
|00004b20| 12 40 45 78 74 72 61 63 | 74 20 74 68 65 20 74 79 |.@Extrac|t the ty|
|00004b30| 70 65 49 6e 73 65 72 74 | 69 6f 6e 4c 6f 63 20 73 |peInsert|ionLoc s|
|00004b40| 74 72 75 63 74 75 72 65 | 20 28 73 74 6f 72 65 64 |tructure| (stored|
|00004b50| 20 75 6e 64 65 72 20 74 | 68 65 20 6b 65 79 77 6f | under t|he keywo|
|00004b60| 72 64 2a 0d 30 d2 6b 65 | 79 41 45 49 6e 73 65 72 |rd*.0.ke|yAEInser|
|00004b70| 74 48 65 72 65 d3 29 20 | 61 6e 64 20 63 6f 65 72 |tHere.) |and coer|
|00004b80| 63 65 20 69 74 20 74 6f | 20 61 6e 20 41 45 52 65 |ce it to| an AERe|
|00004b90| 63 6f 72 64 2e 0d 00 09 | 28 01 fe 01 92 01 34 04 |cord....|(.....4.|
|00004ba0| 02 0d 00 0c 28 02 13 00 | a2 41 48 69 6e 74 3a 20 |....(...|.AHint: |
|00004bb0| 59 6f 75 20 63 61 6e 20 | 67 65 74 20 74 68 65 20 |You can |get the |
|00004bc0| 41 70 70 6c 65 20 45 76 | 65 6e 74 20 4d 61 6e 61 |Apple Ev|ent Mana|
|00004bd0| 67 65 72 20 74 6f 20 63 | 6f 65 72 63 65 20 74 68 |ger to c|oerce th|
|00004be0| 65 20 73 74 72 75 63 74 | 75 72 65 2a 0c 43 61 75 |e struct|ure*.Cau|
|00004bf0| 74 6f 6d 61 74 69 63 61 | 6c 6c 79 20 62 79 20 73 |tomatica|lly by s|
|00004c00| 70 65 63 69 66 79 69 6e | 67 20 d2 74 79 70 65 41 |pecifyin|g .typeA|
|00004c10| 45 52 65 63 6f 72 64 d3 | 20 61 73 20 74 68 65 20 |ERecord.| as the |
|00004c20| 64 65 73 69 72 65 64 20 | 74 79 70 65 2e 20 54 68 |desired |type. Th|
|00004c30| 65 2a 0c 3e 72 65 73 75 | 6c 74 69 6e 67 20 76 61 |e*.>resu|lting va|
|00004c40| 6c 75 65 20 73 68 6f 75 | 6c 64 20 62 65 20 70 6c |lue shou|ld be pl|
|00004c50| 61 63 65 64 20 69 6e 74 | 6f 20 61 6e 20 41 45 20 |aced int|o an AE |
|00004c60| 44 65 73 63 72 69 70 74 | 6f 72 2c 20 73 6f 20 75 |Descript|or, so u|
|00004c70| 73 65 2a 0c 0a 41 45 47 | 65 74 50 61 72 61 6d 04 |se*..AEG|etParam.|
|00004c80| 06 29 3e 04 44 65 73 63 | 04 02 29 17 01 2e 04 00 |.)>.Desc|..).....|
|00004c90| 28 02 49 00 90 02 33 2e | 29 12 49 45 78 74 72 61 |(.I...3.|).IExtra|
|00004ca0| 63 74 20 74 68 65 20 63 | 6c 61 73 73 20 6f 66 20 |ct the c|lass of |
|00004cb0| 74 68 65 20 6f 62 6a 65 | 63 74 20 74 6f 20 62 65 |the obje|ct to be|
|00004cc0| 20 63 72 65 61 74 65 64 | 2e 54 68 69 73 20 70 61 | created|.This pa|
|00004cd0| 72 61 6d 65 74 65 72 2c | 20 77 68 69 63 68 20 69 |rameter,| which i|
|00004ce0| 73 20 6f 66 2a 0c 3c 74 | 79 70 65 20 d2 74 79 70 |s of*.<t|ype .typ|
|00004cf0| 65 54 79 70 65 d3 2c 20 | 69 73 20 73 74 6f 72 65 |eType., |is store|
|00004d00| 64 20 75 6e 64 65 72 20 | 74 68 65 20 6b 65 79 20 |d under |the key |
|00004d10| d2 6b 65 79 41 45 4f 62 | 6a 65 63 74 43 6c 61 73 |.keyAEOb|jectClas|
|00004d20| 73 d3 2e 22 f0 00 f0 00 | 01 01 a1 00 b6 00 04 00 |s.."....|........|
|00004d30| 06 00 19 20 02 79 00 48 | 02 79 00 d7 a1 00 b6 00 |... .y.H|.y......|
|00004d40| 04 00 19 00 06 a1 00 b6 | 00 04 00 01 00 01 0d 00 |........|........|
|00004d50| 09 28 02 86 00 48 01 33 | 04 01 2a 0c 01 33 04 00 |.(...H.3|..*..3..|
|00004d60| 0d 00 0a 2b 06 03 4b 20 | 54 79 70 65 49 6e 73 65 |...+..K |TypeInse|
|00004d70| 72 74 69 6f 6e 4c 6f 63 | 20 72 65 63 6f 72 64 73 |rtionLoc| records|
|00004d80| 20 61 72 65 20 61 6c 73 | 6f 20 75 73 65 64 20 62 | are als|o used b|
|00004d90| 79 20 74 68 65 20 43 6c | 6f 6e 65 20 61 6e 64 20 |y the Cl|one and |
|00004da0| 4d 6f 76 65 20 41 70 70 | 6c 65 20 65 76 65 6e 74 |Move App|le event|
|00004db0| 73 2e 0d 00 09 28 02 9e | 00 48 01 34 0d 00 0a 2b |s....(..|.H.4...+|
|00004dc0| 05 03 74 20 54 68 65 20 | 41 70 70 6c 65 20 45 76 |..t The |Apple Ev|
|00004dd0| 65 6e 74 20 4d 61 6e 61 | 67 65 72 20 6c 65 74 73 |ent Mana|ger lets|
|00004de0| 20 79 6f 75 20 74 61 6b | 65 20 61 6e 79 20 61 72 | you tak|e any ar|
|00004df0| 62 69 74 72 61 72 79 20 | 41 45 20 52 65 63 6f 72 |bitrary |AE Recor|
|00004e00| 64 20 61 6e 64 20 63 6f | 65 72 63 65 20 69 74 20 |d and co|erce it |
|00004e10| 69 6e 74 6f 20 61 20 63 | 75 73 74 6f 6d 20 74 79 |into a c|ustom ty|
|00004e20| 70 65 20 28 75 73 69 6e | 67 20 61 6e 79 20 74 79 |pe (usin|g any ty|
|00004e30| 70 65 20 63 6f 64 65 28 | 02 ac 00 48 71 79 6f 75 |pe code(|...Hqyou|
|00004e40| 20 63 61 6e 20 69 6e 76 | 65 6e 74 2e 29 20 54 68 | can inv|ent.) Th|
|00004e50| 69 73 20 63 75 73 74 6f | 6d 20 69 74 65 6d 20 63 |is custo|m item c|
|00004e60| 61 6e 20 62 65 20 70 6c | 61 63 65 64 20 69 6e 74 |an be pl|aced int|
|00004e70| 6f 20 61 6e 20 41 70 70 | 6c 65 20 65 76 65 6e 74 |o an App|le event|
|00004e80| 20 61 6e 64 20 73 65 6e | 74 20 6f 66 66 20 74 6f | and sen|t off to|
|00004e90| 20 61 6e 6f 74 68 65 72 | 20 61 70 70 6c 69 63 61 | another| applica|
|00004ea0| 74 69 6f 6e 2e 20 57 68 | 65 6e 20 74 68 65 2a 0b |tion. Wh|en the*.|
|00004eb0| 76 72 65 63 65 69 76 65 | 72 20 65 78 74 72 61 63 |vreceive|r extrac|
|00004ec0| 74 73 20 74 68 65 20 63 | 75 73 74 6f 6d 20 70 61 |ts the c|ustom pa|
|00004ed0| 72 61 6d 65 74 65 72 2c | 20 69 74 20 63 61 6e 20 |rameter,| it can |
|00004ee0| 61 73 6b 20 74 68 65 20 | 41 70 70 6c 65 20 45 76 |ask the |Apple Ev|
|00004ef0| 65 6e 74 20 4d 61 6e 61 | 67 65 72 20 74 6f 20 72 |ent Mana|ger to r|
|00004f00| 65 2d 63 6f 65 72 63 65 | 20 74 68 65 20 64 61 74 |e-coerce| the dat|
|00004f10| 61 20 69 6e 74 6f 20 61 | 6e 20 41 45 20 52 65 63 |a into a|n AE Rec|
|00004f20| 6f 72 64 20 61 6e 64 2a | 0b 26 74 68 65 6e 20 61 |ord and*|.&then a|
|00004f30| 63 63 65 73 73 20 74 68 | 65 20 66 69 65 6c 64 73 |ccess th|e fields|
|00004f40| 20 6f 66 20 74 68 61 74 | 20 72 65 63 6f 72 64 2e | of that| record.|
|00004f50| 2a 16 6e 54 68 69 73 20 | 74 65 63 68 6e 69 71 75 |*.nThis |techniqu|
|00004f60| 65 20 61 6c 6c 6f 77 73 | 20 79 6f 75 20 74 6f 20 |e allows| you to |
|00004f70| 73 65 6e 64 20 61 72 62 | 69 74 72 61 72 79 20 64 |send arb|itrary d|
|00004f80| 61 74 61 20 73 74 72 75 | 63 74 75 72 65 73 20 28 |ata stru|ctures (|
|00004f90| 73 74 75 66 66 65 64 20 | 69 6e 74 6f 20 41 45 20 |stuffed |into AE |
|00004fa0| 52 65 63 6f 72 64 73 20 | 61 6e 64 20 74 68 65 6e |Records |and then|
|00004fb0| 20 63 6f 65 72 63 65 64 | 29 20 62 65 74 77 65 65 | coerced|) betwee|
|00004fc0| 6e 2a 0b 32 61 70 70 6c | 69 63 61 74 69 6f 6e 73 |n*.2appl|ications|
|00004fd0| 20 77 69 74 68 20 61 20 | 66 61 69 72 20 64 65 67 | with a |fair deg|
|00004fe0| 72 65 65 20 6f 66 20 65 | 72 72 6f 72 20 63 68 65 |ree of e|rror che|
|00004ff0| 63 6b 69 6e 67 2e 0d 00 | 0c 2a 0b 14 44 65 76 65 |cking...|.*..Deve|
|00005000| 6c 6f 70 65 72 20 55 6e | 69 76 65 72 73 69 74 79 |loper Un|iversity|
|00005010| 29 e0 02 2d 20 29 07 01 | 37 29 06 02 20 2d 29 95 |)..- )..|7).. -).|
|00005020| 18 52 65 67 69 73 74 72 | 79 20 2f 20 44 31 20 20 |.Registr|y / D1 |
|00005030| 4c 61 62 20 4e 6f 74 65 | 73 ff 00 0c 00 00 00 00 |Lab Note|s.......|
|00005040| 02 d7 02 23 11 01 0c 00 | 1e 00 1f 01 00 0a 00 00 |...#....|........|
|00005050| 00 00 03 15 02 5f 2c 00 | 08 00 14 05 54 69 6d 65 |....._,.|....Time|
|00005060| 73 03 00 14 0d 00 0c 2e | 00 04 00 00 00 00 2b a2 |s.......|......+.|
|00005070| 2d 43 53 69 6e 63 65 20 | 77 65 20 68 61 76 65 20 |-CSince |we have |
|00005080| 64 65 63 69 64 65 64 20 | 65 61 63 68 20 6f 62 6a |decided |each obj|
|00005090| 65 63 74 20 73 68 6f 75 | 6c 64 20 62 65 20 72 65 |ect shou|ld be re|
|000050a0| 73 70 6f 6e 73 69 62 6c | 65 20 66 6f 72 20 69 74 |sponsibl|e for it|
|000050b0| 73 20 6f 77 6e 2a 0c 48 | 63 72 65 61 74 69 6f 6e |s own*.H|creation|
|000050c0| 20 61 6e 64 20 64 65 6c | 65 74 69 6f 6e 2c 20 74 | and del|etion, t|
|000050d0| 68 69 73 20 76 61 6c 75 | 65 20 77 69 6c 6c 20 61 |his valu|e will a|
|000050e0| 6c 73 6f 20 73 65 72 76 | 65 20 61 73 20 74 68 65 |lso serv|e as the|
|000050f0| 20 64 69 73 70 61 74 63 | 68 20 63 6c 61 73 73 2e | dispatc|h class.|
|00005100| 04 02 2a 12 4a 54 68 69 | 73 20 70 61 72 61 6d 65 |..*.JThi|s parame|
|00005110| 74 65 72 20 63 6f 75 6c | 64 20 62 65 20 73 74 6f |ter coul|d be sto|
|00005120| 72 65 64 20 69 6e 20 61 | 20 6c 6f 63 61 6c 20 76 |red in a| local v|
|00005130| 61 72 69 61 62 6c 65 20 | 69 6e 20 79 6f 75 72 20 |ariable |in your |
|00005140| 72 6f 75 74 69 6e 65 2e | 20 49 66 20 79 6f 75 2a |routine.| If you*|
|00005150| 0c 2b 77 69 73 68 20 74 | 6f 20 64 6f 20 74 68 69 |.+wish t|o do thi|
|00005160| 73 2c 20 65 78 74 72 61 | 63 74 20 69 74 20 77 69 |s, extra|ct it wi|
|00005170| 74 68 20 41 45 47 65 74 | 50 61 72 61 6d 04 06 29 |th AEGet|Param..)|
|00005180| ce 04 50 74 72 2e 04 00 | 28 00 69 00 90 02 34 2e |..Ptr...|(.i...4.|
|00005190| 29 12 4a 45 78 74 72 61 | 63 74 20 74 68 65 20 6f |).JExtra|ct the o|
|000051a0| 62 6a 65 63 74 20 73 70 | 65 63 69 66 69 65 72 20 |bject sp|ecifier |
|000051b0| 63 6f 6e 74 61 69 6e 65 | 64 20 77 69 74 68 69 6e |containe|d within|
|000051c0| 20 74 68 65 20 74 79 70 | 65 49 6e 73 65 72 74 69 | the typ|eInserti|
|000051d0| 6f 6e 4c 6f 63 20 72 65 | 63 6f 72 64 2e 2a 0c 43 |onLoc re|cord.*.C|
|000051e0| 54 68 69 73 20 6f 62 6a | 65 63 74 20 73 70 65 63 |This obj|ect spec|
|000051f0| 69 66 69 65 72 20 69 73 | 20 63 6f 6e 74 61 69 6e |ifier is| contain|
|00005200| 65 64 20 75 6e 64 65 72 | 20 74 68 65 20 6b 65 79 |ed under| the key|
|00005210| 77 6f 72 64 20 d2 6b 65 | 79 41 45 4f 62 6a 65 63 |word .ke|yAEObjec|
|00005220| 74 d3 2e 04 02 2a 12 46 | 4e 6f 74 65 3a 20 53 69 |t....*.F|Note: Si|
|00005230| 6e 63 65 20 79 6f 75 20 | 61 72 65 20 65 78 74 72 |nce you |are extr|
|00005240| 61 63 74 69 6e 67 20 61 | 6e 20 69 74 65 6d 20 66 |acting a|n item f|
|00005250| 72 6f 6d 20 61 6e 20 41 | 45 20 52 65 63 6f 72 64 |rom an A|E Record|
|00005260| 20 69 6e 73 74 65 61 64 | 20 6f 66 20 61 6e 2a 0c | instead| of an*.|
|00005270| 21 41 70 70 6c 65 20 65 | 76 65 6e 74 2c 20 79 6f |!Apple e|vent, yo|
|00005280| 75 20 73 68 6f 75 6c 64 | 20 75 73 65 20 41 45 47 |u should| use AEG|
|00005290| 65 74 04 06 29 aa 03 4b | 65 79 04 02 29 14 1f 44 |et..)..K|ey..)..D|
|000052a0| 65 73 63 20 69 6e 73 74 | 65 61 64 20 6f 66 20 41 |esc inst|ead of A|
|000052b0| 45 47 65 74 50 61 72 61 | 6d 44 65 73 63 2e 28 00 |EGetPara|mDesc.(.|
|000052c0| 9f 00 a2 3c 54 68 65 20 | d2 50 61 72 61 6d d3 20 |...<The |.Param. |
|000052d0| 63 61 6c 6c 73 20 61 72 | 65 20 6f 6e 6c 79 20 64 |calls ar|e only d|
|000052e0| 65 73 69 67 6e 65 64 20 | 74 6f 20 77 6f 72 6b 20 |esigned |to work |
|000052f0| 6f 6e 20 41 70 70 6c 65 | 20 65 76 65 6e 74 73 2e |on Apple| events.|
|00005300| 04 00 28 00 b1 00 90 02 | 35 2e 29 12 49 45 78 74 |..(.....|5.).IExt|
|00005310| 72 61 63 74 20 74 68 65 | 20 d2 70 6f 73 69 74 69 |ract the| .positi|
|00005320| 6f 6e d3 20 63 6f 64 65 | 20 63 6f 6e 74 61 69 6e |on. code| contain|
|00005330| 65 64 20 77 69 74 68 69 | 6e 20 74 68 65 20 74 79 |ed withi|n the ty|
|00005340| 70 65 49 6e 73 65 72 74 | 69 6f 6e 4c 6f 63 20 72 |peInsert|ionLoc r|
|00005350| 65 63 6f 72 64 2e 2a 0c | 1f 54 68 65 20 6b 65 79 |ecord.*.|.The key|
|00005360| 77 6f 72 64 20 69 73 20 | d2 6b 65 79 41 45 50 6f |word is |.keyAEPo|
|00005370| 73 69 74 69 6f 6e d3 2e | 28 00 cf 00 90 02 36 2e |sition..|(.....6.|
|00005380| 29 12 1d 52 65 73 6f 6c | 76 65 20 74 68 65 20 6f |)..Resol|ve the o|
|00005390| 62 6a 65 63 74 20 73 70 | 65 63 69 66 69 65 72 2e |bject sp|ecifier.|
|000053a0| 28 00 e1 00 90 02 37 2e | 29 12 3e 50 61 73 73 20 |(.....7.|).>Pass |
|000053b0| 74 68 65 20 6f 62 6a 65 | 63 74 20 73 70 65 63 69 |the obje|ct speci|
|000053c0| 66 69 65 72 2c 20 74 68 | 65 20 74 6f 6b 65 6e 2c |fier, th|e token,|
|000053d0| 20 61 6e 64 20 74 68 65 | 20 70 6f 73 69 74 69 6f | and the| positio|
|000053e0| 6e 20 63 6f 64 65 20 74 | 6f 2a 0c 13 6c 61 62 5f |n code t|o*..lab_|
|000053f0| 53 65 6e 64 41 45 54 6f | 4f 62 6a 65 63 74 2e 04 |SendAETo|Object..|
|00005400| 02 2a 12 3e 49 4d 50 4f | 52 54 41 4e 54 20 4e 4f |.*.>IMPO|RTANT NO|
|00005410| 54 45 3a 20 53 69 6e 63 | 65 20 77 65 d5 72 65 20 |TE: Sinc|e we.re |
|00005420| 6e 6f 74 20 75 73 69 6e | 67 20 74 68 65 20 72 65 |not usin|g the re|
|00005430| 66 63 6f 6e 20 70 61 72 | 61 6d 65 74 65 72 20 66 |fcon par|ameter f|
|00005440| 6f 72 2a 0c 4a 61 6e 79 | 74 68 69 6e 67 20 65 6c |or*.Jany|thing el|
|00005450| 73 65 2c 20 61 6e 64 20 | 69 74 d5 73 20 61 20 66 |se, and |it.s a f|
|00005460| 75 6c 6c 20 33 32 20 62 | 69 74 73 2c 20 79 6f 75 |ull 32 b|its, you|
|00005470| 20 73 68 6f 75 6c 64 20 | 70 6c 61 63 65 20 74 68 | should |place th|
|00005480| 65 20 70 6f 73 69 74 69 | 6f 6e 20 63 6f 64 65 2a |e positi|on code*|
|00005490| 0c 42 69 6e 74 6f 20 74 | 68 65 20 72 65 66 63 6f |.Binto t|he refco|
|000054a0| 6e 20 70 61 72 61 6d 65 | 74 65 72 2e 20 49 66 20 |n parame|ter. If |
|000054b0| 79 6f 75 20 64 6f 6e d5 | 74 20 64 6f 20 74 68 69 |you don.|t do thi|
|000054c0| 73 2c 20 62 6f 74 68 20 | 74 68 65 20 62 75 69 6c |s, both |the buil|
|000054d0| 74 2d 69 6e 2a 0c 46 69 | 6d 70 6c 65 6d 65 6e 74 |t-in*.Fi|mplement|
|000054e0| 61 74 69 6f 6e 73 20 6f | 66 20 43 72 65 61 74 65 |ations o|f Create|
|000054f0| 20 45 6c 65 6d 65 6e 74 | 20 61 6e 64 20 79 6f 75 | Element| and you|
|00005500| 72 20 6c 61 62 20 69 6d | 70 6c 65 6d 65 6e 74 61 |r lab im|plementa|
|00005510| 74 69 6f 6e 20 6f 66 20 | 74 68 69 73 20 04 06 28 |tion of |this ..(|
|00005520| 01 23 01 f3 04 77 69 6c | 6c 28 01 2f 00 a2 08 6e |.#...wil|l(./...n|
|00005530| 6f 74 20 77 6f 72 6b 04 | 02 29 2b 01 2e 04 01 28 |ot work.|.)+....(|
|00005540| 01 47 00 6c 08 54 65 73 | 74 69 6e 67 3a 04 00 2b |.G.l.Tes|ting:..+|
|00005550| 24 18 22 53 65 65 20 74 | 68 65 20 6c 61 62 20 d2 |$."See t|he lab .|
|00005560| 52 65 67 69 73 74 72 79 | 2f 44 32 2c 20 50 61 72 |Registry|/D2, Par|
|00005570| 74 20 34 2e d3 04 05 28 | 01 77 00 6c 18 52 65 71 |t 4....(|.w.l.Req|
|00005580| 75 69 72 65 64 20 53 68 | 65 6c 6c 20 55 74 69 6c |uired Sh|ell Util|
|00005590| 69 74 69 65 73 04 00 29 | 86 01 3a 2c 00 0a 00 16 |ities..)|..:,....|
|000055a0| 07 43 6f 75 72 69 65 72 | 03 00 16 0d 00 09 28 01 |.Courier|......(.|
|000055b0| 8e 00 7e 04 6e 6f 6e 65 | 03 00 14 04 05 0d 00 0c |..~.none|........|
|000055c0| 28 01 a5 00 6c 14 52 65 | 71 75 69 72 65 64 20 4f |(...l.Re|quired O|
|000055d0| 53 20 52 6f 75 74 69 6e | 65 73 04 00 29 7e 01 3a |S Routin|es..)~.:|
|000055e0| 03 00 16 0d 00 09 28 01 | b6 00 7e 4a 70 61 73 63 |......(.|..~Jpasc|
|000055f0| 61 6c 20 4f 53 45 72 72 | 20 41 45 47 65 74 41 74 |al OSErr| AEGetAt|
|00005600| 74 72 69 62 75 74 65 50 | 74 72 20 28 63 6f 6e 73 |tributeP|tr (cons|
|00005610| 74 20 41 70 70 6c 65 45 | 76 65 6e 74 20 2a 74 68 |t AppleE|vent *th|
|00005620| 65 41 70 70 6c 65 45 76 | 65 6e 74 2c 20 41 45 4b |eAppleEv|ent, AEK|
|00005630| 65 79 57 6f 72 64 2b 5a | 0a 3b 74 68 65 41 45 4b |eyWord+Z|.;theAEK|
|00005640| 65 79 77 6f 72 64 2c 20 | 44 65 73 63 54 79 70 65 |eyword, |DescType|
|00005650| 20 64 65 73 69 72 65 64 | 54 79 70 65 2c 20 44 65 | desired|Type, De|
|00005660| 73 63 54 79 70 65 20 2a | 74 79 70 65 43 6f 64 65 |scType *|typeCode|
|00005670| 2c 20 50 74 72 2a 0a 2d | 64 61 74 61 50 74 72 2c |, Ptr*.-|dataPtr,|
|00005680| 20 53 69 7a 65 20 6d 61 | 78 69 6d 75 6d 53 69 7a | Size ma|ximumSiz|
|00005690| 65 2c 20 53 69 7a 65 20 | 2a 61 63 74 75 61 6c 53 |e, Size |*actualS|
|000056a0| 69 7a 65 29 3b 28 01 da | 00 7e 54 70 61 73 63 61 |ize);(..|.~Tpasca|
|000056b0| 6c 20 4f 53 45 72 72 20 | 41 45 47 65 74 50 61 72 |l OSErr |AEGetPar|
|000056c0| 61 6d 44 65 73 63 28 63 | 6f 6e 73 74 20 41 70 70 |amDesc(c|onst App|
|000056d0| 6c 65 45 76 65 6e 74 20 | 2a 74 68 65 41 70 70 6c |leEvent |*theAppl|
|000056e0| 65 45 76 65 6e 74 2c 20 | 41 45 4b 65 79 57 6f 72 |eEvent, |AEKeyWor|
|000056f0| 64 20 74 68 65 41 45 4b | 65 79 77 6f 72 64 2c 2b |d theAEK|eyword,+|
|00005700| 5a 0a 26 44 65 73 63 54 | 79 70 65 ca 64 65 73 69 |Z.&DescT|ype.desi|
|00005710| 72 65 64 54 79 70 65 2c | 20 41 45 44 65 73 63 20 |redType,| AEDesc |
|00005720| 2a 72 65 73 75 6c 74 29 | 3b 28 01 f4 00 7e 4b 70 |*result)|;(...~Kp|
|00005730| 61 73 63 61 6c 20 4f 53 | 45 72 72 20 41 45 52 65 |ascal OS|Err AERe|
|00005740| 73 6f 6c 76 65 20 28 63 | 6f 6e 73 74 20 41 45 44 |solve (c|onst AED|
|00005750| 65 73 63 20 2a 6f 62 6a | 65 63 74 53 70 65 63 69 |esc *obj|ectSpeci|
|00005760| 66 69 65 72 2c 20 73 68 | 6f 72 74 20 63 61 6c 6c |fier, sh|ort call|
|00005770| 62 61 63 6b 46 6c 61 67 | 73 2c 2b 5a 0a 12 41 45 |backFlag|s,+Z..AE|
|00005780| 44 65 73 63 ca 2a 74 68 | 65 54 6f 6b 65 6e 29 3b |Desc.*th|eToken);|
|00005790| 28 02 0e 00 7e 55 70 61 | 73 63 61 6c 20 4f 53 45 |(...~Upa|scal OSE|
|000057a0| 72 72 20 41 45 47 65 74 | 4b 65 79 50 74 72 28 63 |rr AEGet|KeyPtr(c|
|000057b0| 6f 6e 73 74 20 41 45 52 | 65 63 6f 72 64 20 2a 74 |onst AER|ecord *t|
|000057c0| 68 65 41 45 52 65 63 6f | 72 64 2c 41 45 4b 65 79 |heAEReco|rd,AEKey|
|000057d0| 77 6f 72 64 20 74 68 65 | 41 45 4b 65 79 77 6f 72 |word the|AEKeywor|
|000057e0| 64 2c 20 44 65 73 63 54 | 79 70 65 2b 5a 0a 3f 64 |d, DescT|ype+Z.?d|
|000057f0| 65 73 69 72 65 64 54 79 | 70 65 2c 20 44 65 73 63 |esiredTy|pe, Desc|
|00005800| 54 79 70 65 20 2a 74 79 | 70 65 43 6f 64 65 2c 20 |Type *ty|peCode, |
|00005810| 50 74 72 20 64 61 74 61 | 50 74 72 2c 20 53 69 7a |Ptr data|Ptr, Siz|
|00005820| 65 20 6d 61 78 69 6d 75 | 6d 53 69 7a 65 2c 2a 0a |e maximu|mSize,*.|
|00005830| 12 53 69 7a 65 20 2a 61 | 63 74 75 61 6c 53 69 7a |.Size *a|ctualSiz|
|00005840| 65 29 3b 28 02 32 00 7e | 4e 70 61 73 63 61 6c 20 |e);(.2.~|Npascal |
|00005850| 4f 53 45 72 72 20 41 45 | 47 65 74 4b 65 79 44 65 |OSErr AE|GetKeyDe|
|00005860| 73 63 28 63 6f 6e 73 74 | 20 41 45 52 65 63 6f 72 |sc(const| AERecor|
|00005870| 64 20 2a 74 68 65 41 45 | 52 65 63 6f 72 64 2c 20 |d *theAE|Record, |
|00005880| 41 45 4b 65 79 77 6f 72 | 64 20 74 68 65 41 45 4b |AEKeywor|d theAEK|
|00005890| 65 79 77 6f 72 64 2c 2b | 5a 0a 25 44 65 73 63 54 |eyword,+|Z.%DescT|
|000058a0| 79 70 65 20 64 65 73 69 | 72 65 64 54 79 70 65 2c |ype desi|redType,|
|000058b0| 20 41 45 44 65 73 63 20 | 2a 72 65 73 75 6c 74 29 | AEDesc |*result)|
|000058c0| 28 02 4c 00 7e 52 70 61 | 73 63 61 6c 20 4f 53 45 |(.L.~Rpa|scal OSE|
|000058d0| 72 72 20 41 45 43 6f 65 | 72 63 65 44 65 73 63 28 |rr AECoe|rceDesc(|
|000058e0| 63 6f 6e 73 74 20 41 45 | 44 65 73 63 20 2a 74 68 |const AE|Desc *th|
|000058f0| 65 41 45 44 65 73 63 2c | 20 44 65 73 63 54 79 70 |eAEDesc,| DescTyp|
|00005900| 65 20 74 6f 54 79 70 65 | 2c 41 45 44 65 73 63 20 |e toType|,AEDesc |
|00005910| 2a 72 65 73 75 6c 74 29 | 03 00 14 0d 00 0c 28 02 |*result)|......(.|
|00005920| ee 00 48 14 44 65 76 65 | 6c 6f 70 65 72 20 55 6e |..H.Deve|loper Un|
|00005930| 69 76 65 72 73 69 74 79 | 29 e0 02 2d 20 29 07 01 |iversity|)..- )..|
|00005940| 38 29 06 02 20 2d 29 95 | 18 52 65 67 69 73 74 72 |8).. -).|.Registr|
|00005950| 79 20 2f 20 44 31 20 20 | 4c 61 62 20 4e 6f 74 65 |y / D1 |Lab Note|
|00005960| 73 ff 00 00 00 10 00 00 | 18 ac 00 00 20 ca 00 00 |s.......|.... ...|
|00005970| 2c 61 00 00 35 41 00 00 | 40 14 00 00 44 fd 00 00 |,a..5A..|@...D...|
|00005980| 50 3a 00 00 59 62 | |P:..Yb | |
+--------+-------------------------+-------------------------+--------+--------+